LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 07-24-2013, 11:17 PM   #1
Daver-007
LQ Newbie
 
Registered: Jul 2013
Posts: 2

Rep: Reputation: Disabled
storing printk message check sum


Dear all,

Background : I want to store the printk message checksum in the dict field of structured log entry.

What I tried : I have made a following changes in the printk.c file,
  • Calculate the message checksum using crc32_le function in vprintk_emit function
  • Append the checksum to the dict field
  • update the dict_len
  • Compile the source


After the successful compilation, I restarted the machine but it didn't start booting now.. It just got stuck..

So, I'm not sure what went wrong?

Any pointers or help is welcome...

Thanks
 
Old 07-30-2013, 01:42 PM   #2
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
It's very hard to say what went wrong. Quite possibly you have a big in your code and this bug crashes the system before it even boots. This is quite probable: printks are used at the boot time.

What you need to do now is to restore the old kernel to be able to boot. Use a live cd or boot with any other spare kernel you have (like the kernel of yur distribution).

Then I recommend you to start making changes one by one, if possible in a virtual machine: it's much easier to fix it. Do not implement everything at once. Just add the field at first, compile, debug. Then add the checksum etc.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Check Sum LinuxNoobX Linux - Newbie 9 01-26-2012 02:09 PM
How to enable printk message on EP9307 (kernel 2.6.8.1) tamamontu Linux - Embedded & Single-board computer 1 02-05-2010 01:36 AM
printk: message ernobe Debian 4 11-20-2004 11:50 AM
redirecting kernel's printk of an error message mwalker_web Linux - Newbie 0 11-14-2003 04:54 PM
Check sum emmanuelmathew Linux - Newbie 2 02-12-2003 01:14 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 11:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration