-   Linux - General (
-   -   ext2 partition screwed? (

LGBR 08-03-2003 02:10 AM

ext2 partition screwed?
I'm using Debian Woody 3.0 on my machine, and I installed it two weeks ago. And now it's having some trouble with the ext2 partition on there. When I boot it says:

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 e2fsck with an alternate superblock:
e2fsck -b 8193 <device>

so I run
e2fsck -b 8193 /dev/hda2

and I got:

e2fsck 1.27 (8-Mar-2002)
e2fsck: Bad magic number in super-block while trying to open /dev/hda2

Same thing happend when I tried just /dev/hda. What should I do?

scott_R 08-03-2003 04:50 AM

I knew I should have written this down. I run debian unstable, and the same thing happened to me about a month ago. Although I can't really help(I've been drinking--it is saturday night :) , I can tell you that it's not something that you need to reinstall debian for, or risk losing your information. If I recall right, it was because my version of lilo was screwed up. When I did my usual updates, I couldn't boot back in.

While I'm not sure that's your case, it could also be a bad kernel config. If you're new at linux, and you don't have anything to lose, a reinstall won't kill you, and might be easier (although it pains me to say that, windows users don't seem to mind). If you're competent with linux, or at least willing to play with linux a little, you might want to look into chroot. I think I fixed it by chrooting into my system from a boot disk, then running lilo from a different version of lilo than I'd just installed.

Like I said, this is a guess, and I've been drinking, so I'm sorry if this doesn't help. The main reason I posted it was to let you know that it's just an oddball error, not something that means your system is trashed, or really hard to fix. It took me only a couple minutes to fix it once I understood what was wrong...and of course, I forgot to write it down. :(

zero_copy 08-03-2003 07:42 AM

if you boot with lilo, then try this:

if you can, check the lilo.conf file and make sure that the info specifying boot partitions is correct, if it is go ahead and run 'lilo' to reinstall your bootloader(if your using lilo).

hope that helps....

LGBR 08-03-2003 06:13 PM

nothing worked. my lilo.conf looks fine. I'm assuming I have to reformat or something?

Corin 08-03-2003 09:27 PM

Before doing anything as drastic as that, can we see your /etc/fstab?

And fsck works on file systems in partitions /dev/hda1, /dev/sda1 etc not on whole disks /dev/hda, /dev/sda etc.

All times are GMT -5. The time now is 02:39 PM.