Re: Shorewall logging to stdout
On Thu, Mar 08, 2007 at 08:34:20 -0300, Cassiano Leal wrote:
> Andrei Popescu wrote:
> >Cassiano Leal <firstname.lastname@example.org> wrote:
> >>I have two shorewall installations, and it seems to have a quite
> >>annoying habit of logging to the stdout.
> ># /etc/sysctl.conf - Configuration file for setting system variables
> ># See sysctl.conf (5) for information.
> ># Uncomment the following to stop low-level messages on console
> >kernel.printk = 4 4 1 7
> Ok, I'll try that too.
> Where can I find a better explanation to exactly what these settings do?
You can install the documentation package for your kernel, which will be
called kernel-doc-<version> (for older kernels) or linux-doc-<version>
(for newer kernels). <version> is a string denoting the kernel version;
see the output of the "uname -r" command on your machine. Then you can
find documentation on sysctl in the directory
where <packagename> is the name of the documentation package that you
installed. I have quoted the relevant part of "kernel.txt.gz" at the end
of this message.
> And: do I need to restart any services in order for it to work?
The settings in /etc/sysctl.conf take effect at the next reboot. You can
change the printk setting with immediate effect with
echo "4 1 1 7" > /proc/sys/kernel/printk
and you can check the setting with
Only root can change the setting but everyone can read it.
The files in /proc/ are pseudo-files which provide interfaces to kernel
data structures; see "man proc" for details.
The four values in printk denote: console_loglevel,
default_message_loglevel, minimum_console_loglevel and
These values influence printk() behavior when printing or
logging error messages. See 'man 2 syslog' for more info on
the different loglevels.
- console_loglevel: messages with a higher priority than
this will be printed to the console
- default_message_level: messages without an explicit priority
will be printed with this priority
- minimum_console_loglevel: minimum (highest) value to which
console_loglevel can be set
- default_console_loglevel: default value for console_loglevel