Re: syslog warning: was: Re: [PATCH v6 04/11] printk: Support toggling per-console loglevel via syslog() and cmdline
From: Petr Mladek
Date: Fri Nov 15 2024 - 06:36:51 EST
On Thu 2024-11-14 13:53:40, Chris Down wrote:
> Petr Mladek writes:
> > I see this warning during every boot because rsyslogd() modifies the
> > global loglevel.
> >
> > [...]
> >
> > I am not sure if we have already discussed this in the past.
> > But I would prefer the compromise after all.
>
> I initially implemented that way until v4, but during the v3 review, as I
> understood it you recommended changing it to use
> !ignore_per_console_loglevel based on the assumption that
> SYSLOG_ACTION_CONSOLE_{ON,OFF} wasn't widely used. Maybe I misunderstood
> what was intended?
The current solution of SYSLOG_ACTION_CONSOLE_{ON,OFF} is fine. I
still hope that it is not used much.
My concern is with SYSLOG_ACTION_CONSOLE_LEVEL. It seems to be used
by rsyslogd.
But wait! I see the warning only on SLE15-SP3 which I use for
testing. It is a pretty old system. I see that rsyslogd is not
longer used on never systems. I guess that it has been obsoleted
by systemd journal.
> Happy to revert to the previous approach with warn_on_local_loglevel(), just
> let me know :-)
No, I take it back ;-) Let's keep it simple as it is done in this patch [v6].
We could always add more conditions around the warning when people
complains.
Best Regards,
Petr