LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   fsck error during boot (https://www.linuxquestions.org/questions/linux-software-2/fsck-error-during-boot-158646/)

fastly 03-16-2004 06:15 PM

fsck error during boot
 
Hi Linux Users

I am running Gentoo 2004.0 with Kernel 2.6.3-rc1 Gentoo optimised kernel.

I am getting the following error during bootup:

Checking all filesystems
Fsck.ext2: No such file or directory while trying to open /dev/BOOT /dev/BOOT:

The superblock could not be read or does not describe a correct ext2 filesystem. If the device is valid and it really contains an ext2 filesystem (and not swap or ufs or something else), then the superblock is corrupt, and you might try running e2fscj with an alternative superblock:
E2fsck -b 8193 <device>

/dev/hda1: clean, 43/130560 files, 25603/522080 blocks
* Fsck could not correct all errors, manual repair needed [!!]

Give root password for maintenance


At which point i have tried pressing ctrl+d and running fsck... this doesn't solve the problem.

I am worried about running e2fsck because I can a warning saying I may seriously damage the filesystem if I run it on a mounted partition.

This computer has lots of work on (and took 3 days to compile) so I don't want to ruin my hard drive!

Here is my /etc/fstab if this helps:

# /etc/fstab: static file system information.
# $Header: /home/cvsroot/gentoo-src/rc-scripts/etc/fstab,v 1.14 2003/10/13 20:03:38 azarah Exp $

# <fs> <mountpoint> <type> <opts> <dump/pass>

# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
/dev/BOOT /boot ext2 noauto,noatime 1 1
/dev/ROOT / xfs noatime 0 0
/dev/SWAP none swap sw 0 0
/dev/cdroms/cdrom0 /mnt/cdrom iso9660 noauto,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto 0 0

# NOTE: The next line is critical for boot!
none /proc proc defaults 0 0

# none /dev/shm tmpfs defaults 0 0

/dev/hda1 /boot ext2 noauto,noatime 1 2
/dev/hda2 swap sw 0 0
/dev/hda3 / ext3 noatime 0 1

none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0

/dev/cdroms/cdrom0 /mnt/cdrom auto noauto,user 0 0

(i've snipped some comments).

Any sugeestions are greatly appreciated.

Many thanks!

Alex

aaa 03-16-2004 06:23 PM

Boot w/ bootdisk, then run e2fsck from there.

hw-tph 03-16-2004 06:28 PM

Replace /dev/BOOT and so on with the actual device names. Boot using the Gentoo CD, chroot to your install on disk as per the installation instructions and then edit your fstab.

So these lines:
Code:

/dev/BOOT /boot ext2 noauto,noatime 1 1
/dev/ROOT / xfs noatime 0 0
/dev/SWAP none swap sw 0 0

...should probably look something like this:
Code:

/dev/hda1 /boot ext2 noauto,noatime 1 1
/dev/hda3 / reiserfs noatime 0 0
/dev/hda2 none swap sw 0 0

Of course, make sure you're using the correct device names and filesystem types. If you're unsure and didn't jot it down on a note during installation, type fdisk -l /dev/hda (if /dev/hda is the disk you're installing on) to see what partitions you have.

Also remove the duplicate entries you have further down in your fstab.


Håkan

GoatKing 03-17-2004 03:06 PM

Haha, I'm guilty of the same mistake.

Your fstab isn't configured correctly, the lines containing /dev/BOOT and /dev/ROOT are wrong. BOOT should point to your boot partition, and ROOT should be your root partition. For example:

/dev/hdb1 /boot ext2 noauto,noatime 1 1
/dev/hdb3 / xfs noatime 0 0

Hope that helps.


All times are GMT -5. The time now is 04:05 PM.