LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-27-2007, 07:56 PM   #1
greenphreak
LQ Newbie
 
Registered: Jul 2007
Posts: 22

Rep: Reputation: 15
Attempting to recover from kernel panic with bad root inode


Hello.

I have a Microspace PCX48 computer (1GB RAM, 1GHz Celeron373, 512K L2 Cache, 16GB flash disk). It is running Mandriva 2007 Free edition (not spring), and it has three partitions on it: (/boot, /, and swap). It seemed to be working well enough until a few days ago, when it froze. When I rebooted it, it hung during boot, so I booted in the recovery mode of Mandriva. It went through the following commands and froze:

Code:
...
Creating root device
Trying to resume from /dev/hda5
Mounting root fs /dev/root
EXT3-fs corrupt root inode, run e2fsck
mount: error 22 mounting ext3
Switching to new root
Error opening /dev/console!!!!:2
Kernel Panic - not syncing: Attempted to kill init!
So I booted the system using RIP (Recovery Is Possible), and I had no problems mounting the /boot partition; however, when I tried to mount the / partition (/dev/hda6), I received this error:


Code:
# mount /dev/hda6 /mnt/hd
EXT3-fs: corrupt root inode, run e2fsck
So I ran e2fsck on the partition:

Code:
# e2fsck /dev/hda6
Root inode is not a directory.  Clear <y>? y
*** glibc detected *** realloc(): invalid pointer 0x0809aa70
Aborted
#
I'm not sure what to do here. I would like to get access to the data on the drive, but more importantly, I want to know what caused the error in the first place. You see, this computer normally runs isolated and I have to administrate it remotely (I mean *really* remotely, as in on a mountain in the Andes), so I want to make sure this sort of problem doesn't happen again.

What can cause a root inode to fail? RAM, bad hard drive, software errors? I ran memtest86+ on the RAM for a couple of days and it came up negative. Perhaps it is a hardware problem with the 16GB flash drive? Is it normal to get errors with these things? Is there a way I can test it, or should I just format it and run fsck on it to look for bad blocks or some such? Ideas?

Is it even possible to get access to my data on / or is it lost forever?

Why would e2fsck fail when it detects glibc? This seems like it is a problem with RIP as opposed to the file system giving it problems, but I cannot see any reference to such an error with fsck in my googling.

Thanks for the help in advance!
 
Old 08-27-2007, 08:38 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,375

Rep: Reputation: 564Reputation: 564Reputation: 564Reputation: 564Reputation: 564Reputation: 564
In your post Mandriva reports errors on /dev/hda5 and you try to fix /dev/hda6. I assume that this is a typo.


"Is it even possible to get access to my data on / or is it lost forever?"

One thing that you might try is to point e2fsck to an alternate superblock. The superblocks are redundant and the superblock at block 0could be bad while other superblocks are still intact.

e2fsck -b 32768 /dev/hda6

"What can cause a root inode to fail? RAM, bad hard drive, software errors?"

The most likely explanation in your case is that when Mandriva froze some cache buffers did not get written out thus leaving the file system corrupt. This begs the question of why Mandriva froze.

----------------
Steve Stites
 
Old 08-27-2007, 10:23 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,333

Rep: Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176Reputation: 4176
To ensure you use a valid backup superblock, try this to get a list
Code:
dumpe2fs /dev/hda6 | grep -i superb
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Kernel Panic : How To Recover opensrctechie Linux - General 3 12-16-2005 02:51 PM
Kernel Panic : How To Recover opensrctechie Linux - General 3 12-15-2005 05:17 PM
kernel panic: attempting to kill it.. [ITA]freeware Linux - Software 13 10-27-2005 09:04 AM
Redhat 9: Kernel Panic Attempting to kill init gallopa Red Hat 2 01-25-2005 11:15 AM

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

All times are GMT -5. The time now is 03:09 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