Closed tetraf closed 9 months ago
Everything should be going to the console and systemd should redirect it to its journal.
Questions: 1) What version of irqbalance are you using? 2) What happens when you run irqbalance in the foreground manually. Do the logs get printed properly? 3) What does your irqbalance systemd unit file look like? 4) Whats the output of journalctl -u irqbalance?
Everything should be going to the console and systemd should redirect it to its journal.
I'm OK with that, but while \n\n\n-----------------------------------------------------------------------------\n
may be useful in debug mode for console, it's not (IMHO) for logging.
And:
1.9.3 (from archlinux repository: https://archlinux.org/packages/extra/x86_64/irqbalance/)
that:
$ sudo systemctl stop irqbalance
$ sudo irqbalance --foreground
[it runs but print nothing after waiting several minutes while doing other stuff]
$ sudo irqbalance --foreground --journal
[same thing for this command]
If I start it with --debug
it does print lots of lines (including the famous line-jumps-and-dashes).
this one: https://github.com/Irqbalance/irqbalance/blob/v1.9.3/misc/irqbalance.service
that:
$ journalctl -u irqbalance -n 10 -o cat
Selecting irq 40 for rebalancing
Selecting irq 40 for rebalancing
Selecting irq 40 for rebalancing
Selecting irq 40 for rebalancing
I see what you're saying now, you just don't want the delimiter (-----) in the journal output. Yeah, I definately want to keep that for console logging, but we can turn it off for journal output
please test with https://github.com/Irqbalance/irqbalance/pull/282 and confirm that the issue is resolved
It works fine. No blank line written in logs. Thank you :)
Sorry for necro-bumping this, but, is there a plan to create a new release including this soon? Or should I tell the maintainers to cherry-pick the commit.
Thanks!
The latter, a new release just came out a few weeks ago
Hi, the issue still exists in 1, and the patch is in irqbalance-1.9.4-2.fc40. Don't know if there is something I missed? Thanks!
I see this line in the journal as well with 1.9.4. It's pretty confusing.
Does the fedora systemd unit pass --journal to the executable, or does it just redirect foreground console output?
I see this issue on 1.9.4 with the default systemd unit file with and without --journal
.
On my system irqbalance is started by systemd so its logs are retrieved by journald. However, irqbalance emits logs containing only line jumps and dashes which seems to correspond to https://github.com/Irqbalance/irqbalance/blob/v1.9.3/irqbalance.c#L292
But this line mentions
TO_CONSOLE
so I think there is something missing in the log() function.Especially before this line https://github.com/Irqbalance/irqbalance/blob/v1.9.3/irqbalance.h#L141 (and perhaps the line 154). Maybe something like
if (log_mask & mask & TO_SYSLOG)
.