[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: iptables log target logs everything to tty*. Why?



On Sat, Jun 24, 2006 at 01:51:38PM +0200, Erik Persson wrote:
> root@shere:~# cat /proc/sys/kernel/printk
> 3       4       1       7

Cool, I didn't realize this file existed in the /proc filesystem.
Time to review the documentation... ;-)

> man proc reveals that the 1 is the lowest value that console log level 
> may be set to. Thats the reson, I guess, that klogd -c 0 did fail.

Yup, it's based on the loglevels for syslog.  There is no level 0...

> >There might be a slightly easier way...  
> >
> >The dmesg command, in addition to dumping the kernel's message buffer
> >to the screen, can set the maximum priority (number) of messages which
> >get logged to the console.  For example:
> >
> >  dmesg -n 1
> 
> This would do the same thing as klogd -c 1 I guess.

The main difference is that this method lets you change the level on
the fly...  you don't need to restart klogd for this to take effect.
If klogd is not running, do the kernel messages get saved in the
kernel buffer?  With normal syslog messages, of course, you would lose
them...

-- 
Derek D. Martin
http://www.pizzashack.org/
GPG Key ID: 0x81CFE75D

Attachment: pgpjCPZFOQnDa.pgp
Description: PGP signature


Reply to: