printk for debugging Linux Kernel

printk for debugging Linux Kernel

Post by Karthi » Wed, 10 Jul 2002 04:55:44



Hi,

I am trying to write some kernel code. I am using 'printk' function to
put some debugging information into the log files.But sometimes, when
the kernel hangs there is no debug information logged at all. I am
unable to find out where the error is. Is there anything I need to do to
enable this or is there anyway I can flush the messages or something.

I have tried including the line

kern.alert
        /var/log/kermsgs

in syslog.conf file. (I am actually using KERN_ALERT for printing
messages also)

TIA,
Karthik

 
 
 

printk for debugging Linux Kernel

Post by Kasper Dupon » Wed, 10 Jul 2002 06:26:52



> Hi,

> I am trying to write some kernel code. I am using 'printk' function to
> put some debugging information into the log files.But sometimes, when
> the kernel hangs there is no debug information logged at all. I am
> unable to find out where the error is. Is there anything I need to do to
> enable this or is there anyway I can flush the messages or something.

> I have tried including the line

> kern.alert
>         /var/log/kermsgs

> in syslog.conf file. (I am actually using KERN_ALERT for printing
> messages also)

Are you runing X? Don't.
Do you have two computers? Use a serial console.

http://www.daimi.au.dk/~kasperd/comp.os.linux.development.faq.html

--
Kasper Dupont -- der bruger for meget tid p? usenet.