-   Linux - General (
-   -   debugging the linux kernel - strange output in kmsg (

panos_gr 03-06-2012 10:10 AM

debugging the linux kernel - strange output in kmsg
Hello all,

I am debugging the linux kernel (2.6.36) for a networking issue and I have added some printk in the source files.

I am seeing the printouts of the printks in /proc/kmsg but every now and again, I see them in some sort of giberish!!! Some of the letters are missing and then it goes back to normal.

For example, check this out :


<4>[71171.011752] PANOS : in xfrm6_input (xfrm_input.c)
<4>[71171.011854] PANOS : after ipprot->handler in ip6_input_finish
<4>[71171.065506] PANOS : in ip6_inpu_fns
4[17.652 <>711051]PNS:bfr prt>ade ni6iptfns
4[17.657 <>711051]PNS:i fm_c  eoecligxr6rvsi(fm_nu.)<>711052]
4[17.654 AO  nxr6rvsi(fm_nu.)<>711052]
4[17.659 AO  nxr6rv-bfr aln fm_nu xr6iptc
4[17.653 <>711053]PNS:i fm_nu xr_nu.)<>711051]
4[17.667 AO  fe prt>ade ni6iptfns
4[17.121 AO  ni6iptfns
4[17.128 <>711101]PNS:bfr prt>ade ni6iptfns
4[17.123 <>711102]PNS:i fm_c  eoecligxr6rvsi(fm_nu.)<>711102]
4[17.120 AO  nxr6rvsi(fm_nu.)<>711103]
4[17.125 AO  nxr6rv-bfr aln fm_nu xr6iptc
4[17.129 <>711104]PNS:i fm_nu xr_nu.)<>711101]
4[17.137 AO  fe prt>ade ni6iptfns
<4>[71171.559455] PANOS : in ip6_input_finish
<4>[71171.559478] PANOS : before ipprot->handler in ip6_input_finish
<4>[71171.559501] PANOS : after ipprot->handler in ip6_input_finish
<4>[71172.481409] PANOS : in ip6_input_finish

Any idea why this is happening? Any help is really appreciated!

Thanks a lot!

FrankP 03-14-2012 07:15 PM

Hi Panos, if you're hacking the kernel source to be honest you've got to expect weird stuff might happen and you need to have a fall-back plan. Can you re-install a clean kernel to start with? Then if you're going to make changes you should upgrade to a later one, like 2.6.39 or even 3.0.x, and use version control so you can roll back the edits if you notice a problem.

What was the network problem you mention? Maybe a later kernel would provide a fix for it anyway.

panos_gr 03-15-2012 07:19 AM

Hi Frank,

Well, it doesn't seem that my kernel hacking affects this... I have had problems with the 2.6.39 kernel that's why I reverted back to the 2.6.36 which seems very stable to me...

I have to debug something at the networking stack and it doesn't seem to be resolved at later kernels...

FrankP 03-15-2012 09:06 AM

OK, so how about reverting your code changes until you find out exactly which modification introduced the problem?

All times are GMT -5. The time now is 05:31 AM.