?
Solved

Can't boot, the error "VFS: Can't find an ext3 filesystem"

Posted on 2003-03-21
20
Medium Priority
?
1,206 Views
Last Modified: 2013-12-06
Hello,

I'm using redhat 7.3 with ext3 partition.
After tring to reboot the machine hang. here are the last lines on the screen:

Red Hat nash version 3.3.10 starting
Loading jbd module
Journalled Block Device driver loaded
Loading ext3 module
Mounting /proc filesystem
Creating root device
Mounting root filesystem
VFS: Can't find ext3 filesystem on dev ide0(3,1).
mount: error 22 mounting ext3
pivotroot: pivot_root(/sysroot,/sysroot/initrd) failed: 2
Freeing unused kernel memory: 220k freed
Kernel panic: No init found.  Try passing init= option to kernel.

and then the computer dies.

I allso fail to boot from the boot diskete.
Booting form redhat 7.3 cd in rescue mode
say "You don't have any linux partition"

How can I fix it ?
Please help

Addady
0
Comment
Question by:addady
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
20 Comments
 
LVL 20

Expert Comment

by:Gns
ID: 8180535
As I'm sure you've already gathered, the OS can't find any valid root filesystem.

If you boot to rescue mode, what does fdisk -l report for the drives?

-- Glenn
0
 

Author Comment

by:addady
ID: 8180824
fdisk -l output:
           
/dev/hda1 *(boot) 1 9313 74806641 83
....

0
 
LVL 20

Accepted Solution

by:
Gns earned 1000 total points
ID: 8181095
Hm, the "83" partition type is "Linux Native", so that should be OK. And this is all there is? No swap partition, /boot ... Just one big / is it?

Still in rescue mode, if you try to mount it somewhere, what happens then?
mount -t ext2 /dev/hda1 /mnt
should work (if you're using ext3, mounting it as ext2 should still be OK).

If the mount works, do a "chroot /mnt" then check if you are using filesystem labels ... check in the /etc/fstab file, if the first column is something like "LABEL=/", you are.
In that case, check that the label is intact on the filesystem with
e2label /dev/hda1

If the mount doesn't work, try running e2fsck on it. If it complains that it cannot find a superblock, try giving it a backup superblock via the -b option... I'll cut-n-paste the relevant passage from e2fsck here:
       #b superblock
              Instead  of  using  the  normal  superblock,  use an alternative
              superblock specified by superblock.   This  option  is  normally
              used  when the primary superblock has been corrupted.  The loca#
              tion of the backup superblock is dependent on  the  filesystem#s
              blocksize.    For  filesystems  with  1k  blocksizes,  a  backup
              superblock can be found at block 8193; for filesystems  with  2k
              blocksizes,  at  block  16384;  and  for 4k blocksizes, at block
              32768.

              Additional backup superblocks can be  determined  by  using  the
              mke2fs  program  using  the  #n  option  to  print out where the
              superblocks were created.   The #b option to mke2fs, which spec#
              ifies blocksize of the filesystem must be specified in order for
              the superblock locations that are printed out to be accurate.

              If an alternative superblock is specified and the filesystem  is
              not  opened  read#only,  e2fsck  will make sure that the primary
              superblock is  updated  appropriately  upon  completion  of  the
              filesystem check.

-- Glenn
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 20

Expert Comment

by:Gns
ID: 8181164
Note that the - (dash) got replaced with # (hash) in the paste above....grmbl.

Also note that you probably have a blocksize of 4K, so your first backup superblock is probably at 32768, so you can try with
e2fsck -b 32768 /dev/hda1
if a plain e2fsck doesn't work.

-- Glenn
0
 

Author Comment

by:addady
ID: 8181838
Hello Glenn

I could not mount it and was super disk problems so I did:
e2fsck -b 32768 /dev/hda1
there whore some problem it fix.

But now it fail to boot on:
...
ext3 : No journal on filesystem on ide0(3,1)
...

I guess after the e2fsck in is no longer ext3

now when booting using the rescue I cam mount it !
but commands like ls and vi are not available in this mode.

>Hm, the "83" partition type is "Linux Native", so that >should be OK. And this is all there is? No swap >partition, /boot ... Just one big / is it?

ther is allso swap and fat(unuse) partition I did mention.
0
 
LVL 2

Expert Comment

by:haydes007
ID: 8181976
A better filesystem utility to use is tune2fs. It blows fsck out of the water.
0
 
LVL 20

Expert Comment

by:Gns
ID: 8182592
Apples and pears haydes007, apples and pears...
They perform completely different tasks... which is evident from their names, and even more so from their man-pages. tune2fs will not repair filesystem damage, while e2fsck will not finetune filesystem parameters.

The problem now addady is that you have converted your fileystem to ext2... One of the  things e2fsck's done is to remove the journal (actually "corrected" the parameter telling that there is one).
So the remedy is real simple... Just add it again:-).
I recommend this over changeing your /etc/fstab file (making it refkect that / now is ext2) because of the added security features of ext3. Might It be that you have a plain vanilla 7.3 install? ISTR there being issues with ext3 ... possibly massive filesystem damage resulting from a flaw... Check that you have updated to the latest kernel after you get it booting again;-). IIRC that should fix any issues.

How to add the journal?
Simply (yes haydes007, now you need tune2fs:-)
tune2fs -j /dev/hda1
from the rescue boot.

-- Glenn
0
 
LVL 20

Expert Comment

by:Gns
ID: 8182614
"refkect" == "reflect"

-- Glenn (a.k.a. Le Grand Typo)
0
 

Author Comment

by:addady
ID: 8182812
I tune2fs -j /dev/hda1 and now it continue
to boot and hang in:

Stating system logger
and hang
It seems to me that some important file are missing

>Might It be that you have a plain vanilla 7.3 install?
No I update the kernel some time ago.

I tryed to mount this partition from the rescue disk
to look around, but after the mount command all the shell commands are gone.  So I can't copy or edit files.
0
 
LVL 20

Expert Comment

by:Gns
ID: 8183912
How did you mount it?
Or do you mean after the chroot I suggested?

What seems to be becoming clear is that for some reason (as of yet, and perhaps forever, undetermined) your filesystem might have experienced massive filesystem damage.
If that is the case, you should perhaps not try the chroot, but rather constrain yourself to the tolls provided by the rescuemode shell.

If it hangs on starting syslog, everything cannot be lost... at least it finds the kernel, and _some_ files... even init:-).

Depending on how much damage there is (look in /lost+found on /dev/hda1, fsck will have put "salvaged files" there... the ones it couldn't determine where else to put), you might be forced to reinstall. If you have the space, you could back up any files that you deem irreplaceable (and that isn't to damaged) in a tar archive on your fat partition... that way they will be easy to restore after the reinstall.

Exactly what happened here isn't really possible to tell. One theory could be that the journal got corrupted, and "corrected" the filesytem into oblivion upon the reboot... or something entirely different.

-- Glenn
0
 

Author Comment

by:addady
ID: 8184000
I tune2fs -j /dev/hda1 and now it continue
to boot and hang in:

Stating system logger
and hang
It seems to me that some important file are missing

>Might It be that you have a plain vanilla 7.3 install?
No I update the kernel some time ago.

I tryed to mount this partition from the rescue disk
to look around, but after the mount command all the shell commands are gone.  So I can't copy or edit files.
0
 

Author Comment

by:addady
ID: 8184019
I tune2fs -j /dev/hda1 and now it continue
to boot and hang in:

Stating system logger
and hang
It seems to me that some important file are missing

>Might It be that you have a plain vanilla 7.3 install?
No I update the kernel some time ago.

I tryed to mount this partition from the rescue disk
to look around, but after the mount command all the shell commands are gone.  So I can't copy or edit files.
0
 

Author Comment

by:addady
ID: 8184069
Sorry abut the last two port ( I hit refrash)

>How did you mount it?
>Or do you mean after the chroot I suggested?

#mount -t ext2 /dev/hda1 /mnt
#chroot /mnt
sh: chroot: command not found
(amy command will not work from this point)

if I will reinstall do I have to format the partition and loss at the data ?
Is there any other way to be able to access the data beside redhat rescue ?
0
 
LVL 20

Expert Comment

by:Gns
ID: 8185714
You might be able to use explore2fs from windows (get it at http://uranus.it.swin.edu.au/~jn/linux/explore2fs.htm)

-- Glenn
0
 

Author Comment

by:addady
ID: 8185798
if I will reinstall linux (red-hat 7.3)on the same partition will I loss the previous data (e.g. /home)?

Do you think upgrade to red-hat 8 (using the redhat upgrade option) will rebuild all the currpt system files ?
0
 

Author Comment

by:addady
ID: 8185897
OK , I add 2nd hard disk.  define the new disk as master, and the old disk as slave (now is hdb[1]).
I install redhat 8.0 on the new disk. and mount the old one
as read only.  I can see all the files !

My question is:
Can I some how re activeate the old system with the old disk?. I save me data but I want allso to save the time of installing  and redefineing  all softwares etc.
0
 

Expert Comment

by:Spurgeon
ID: 8186935
when you tuned your fs
tune2fs -j /*/*
it converted your system to ext3
so you'll also have to update your /etc/fstab
put ext3 instead of ext2
0
 

Author Comment

by:addady
ID: 8187225
Spurgeon,
Why do you think it will work ?
look at my note from 03/21/2003 01:53PM PST

0
 
LVL 20

Expert Comment

by:Gns
ID: 8189541
Great going adaddy!

So... now we really could start "thrashing" the 7.3 install:-).

Keep the old disk as slave, add an entry for it in the bootloader (grub? that's the default), and, very important(!), from the RH8 install _relabel_ the 7.3 partition with something distinctive like "e2label /dev/hdb1 73_/" and make the 7.3 /etc/fstab reflect that change, or go with the actual device handle /dev/hdb1 in the 7.3 /etc/fstab.

And that is more or less it!

You should then be able to boot either 8.0, 7.3 or windows... (provided rh8 found/added your windows part;).

What happens if you mount the rh7.3 filesystem as read-write from rh8?

-- Glenn
0
 
LVL 20

Expert Comment

by:Gns
ID: 8189549
You can probably find out a more or less correct entry fro grub in /<wherever_you_mounted7.3>/boot/grub/menu.lst (On RHs this is usually a symlink to grub.conf). Just remeber to change the "root (hd0,0)" to "root (hd1,0)" (or whatever is appropriate) since the drive now is "the second".

-- Glenn
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
This post contains step-by-step instructions for setting up alerting in Percona Monitoring and Management (PMM) using Grafana.
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question