error on booting up mounting an external usb-drive

Bug #97206 reported by Björn Röder
8
Affects Status Importance Assigned to Milestone
Ubuntu
Invalid
Undecided
Unassigned

Bug Description

I use an partitioned external USB-drive which I try to permanently mount as /dev/sdb1 and /dev/sdb2. It actually works quite well except it stops boot procedure printing the following error.

At prompt I just enter 'exit' and it will just boot fine mounting the drives at the right locations. The drives are formatted as ext3 each.

fsck 1.40-WIP (14-Nov-2006)
fsck.ext3: No such file or directory while trying to open /dev/sdb1

/dev/sdb1:
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>

fsck.ext3: No such file or directory while trying to open /dev/sdb2

/dev/sdb2:
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>

fsck died with exit status 8

ProblemType: Bug
Architecture: i386
Date: Wed Mar 28 00:47:29 2007
DistroRelease: Ubuntu 7.04
Uname: Linux bjoern 2.6.20-13-386 #2 Sun Mar 25 00:18:53 UTC 2007 i686 GNU/Linux

Revision history for this message
Brian Murray (brian-murray) wrote :

Thanks for taking the time to report this bug and helping to make Ubuntu better. Do you mean that fsck died with exit status 8 when you executed the command recommended? Thanks in advance.

Revision history for this message
Björn Röder (overgee) wrote :

Thanks for replying to my report. I just found out that the problem cannot be reproduced anymore after one of the recent kernel updates.

Revision history for this message
Brian Murray (brian-murray) wrote :

This bug report is being closed due to your last comment regarding this being fixed with an update. Thanks again for taking the time to report this bug and helping to make Ubuntu better. Feel free to submit any future bugs you may find.

Revision history for this message
Nicholas Stack (nickstack) wrote :

Just encountered a variant of this in Hardy this morning. I had a single FAT 16 partition USB flash drive connected to my computer. For some reason at boot up fsck was seeing it as /dev/sdb; normally my first hard drive is mounted at /dev/sda , my second hard drive is /dev/sdb , and since Hardy install the USB flash is /dev/sdc. Fsck wanted to check the file system on my second hard drive, however, due the mount order issue it tried to fsck the USB flash drive. That caused this error:

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>

fsck died with exit status 8

I rebooted and the same problem happened. I turned off my computer, removed the USB drive, and rebooted fsck ran normally and checked my second hard disk and my computer booted normally. Unlike the OP I could not simply type exit and have the drives mounted in the correct locations. If I did that, on log in I got an error about how my home directory was unable to be found.

ProblemType: Bug
Architecture: i386
Date: Sunday Apr 27 2008
DistroRelease: Ubuntu 8.04
Uname -r: 2.6.24-16-386

Revision history for this message
Nicholas Stack (nickstack) wrote :

Seems to be a regression in Hardy; bug exists again.

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

I am also seeing this problem quite often when I boot into Hardy, with the possibly relevant difference that this is an onboard HDD giving me trouble - no USB involved.

If I get this bug once I can expect it several times in the following reboot attempts. At some point it stops happening and then I can expect it to continue booting fine for a while. I have not yet found any pattern.

The log at /var/log/fsck/checkfs reads exactly like the one starting this bug report, but refers of course to my own drive with: "fsck.ext3: No such file or directory while trying to open /dev/sdb6"

When started like this 'print' in Ubuntu doesn't even see sdb, my storage SATA 300GB HDD. None of the 5 partitions are mounted even though only sdb6 actually fails. Why doesn't it try to mount the others?

## Output from running 'parted' as root:
root@duncan-desktop:~# parted
GNU Parted 1.7.1
Using /dev/sda
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print all

Disk /dev/sda: 41,1GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number Start End Size Type File system Flags
 1 32,3kB 39,4GB 39,4GB primary ext3 boot
 2 39,4GB 41,1GB 1736MB extended
 5 39,4GB 41,1GB 1736MB logical linux-swap
## End of output. I will add the correct output from 'parted' next time it starts correctly.

Running e2fsck with the 'Use alternate block' flag (-b) makes no difference to the results:

## cli output of 'e2fsck -b 8193 /dev/sdb' (same result for '/dev/sdb6', and '/dev/sda' reports device busy, so e2fsck seems to be working.)
root@duncan-desktop:~# e2fsck -b 8193 /dev/sdb
e2fsck 1.40.8 (13-Mar-2008)
e2fsck: No such file or directory while trying to open /dev/sdb
[...]
## End of output

Any ideas out there? This makes my system pretty much unusable.

PS: in case it turns out to be relevant here are some specs:
* Processor is Intel Celeron CPU 2.4GHz
* Ubuntu 8.04 is installed on Primary HDD which is a 40GB ATA drive
* /dev/sdb is a 300GB SATA drive, and I've had a lot of trouble trying different configurations to make my MB see both drives an work, so it's possible this is actually a problem with a BIOS setting.

PPS: in the recovery shell I usually run 'shutdown -h now' but it always just continues to boot. I really don't understand this! Why doesn't it shut down?

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

It started perfectly this time, so here is what parted has to say:

duncan@duncan-desktop:~$ sudo parted
[sudo] password for duncan:
GNU Parted 1.7.1
Using /dev/sda
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print all

Disk /dev/sda: 41,1GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number Start End Size Type File system Flags
 1 32,3kB 39,4GB 39,4GB primary ext3 boot
 2 39,4GB 41,1GB 1736MB extended
 5 39,4GB 41,1GB 1736MB logical linux-swap

Disk /dev/sdb: 300GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number Start End Size Type File system Flags
 1 32,3kB 206GB 206GB primary fat32
 2 206GB 218GB 11,5GB extended
 5 206GB 207GB 1045MB logical linux-swap
 6 207GB 218GB 10,5GB logical ext3
 3 218GB 300GB 82,4GB primary fat32
(parted)

Revision history for this message
Brian Murray (brian-murray) wrote :

Could you please add the full contents of your '/etc/fstab'? Thanks in advance.

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

Here's the contents of my fstab file. I have now completely changed my disc layout.

# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc defaults 0 0
# /dev/sda1
UUID=f3e8ba47-dd1c-4393-97d5-e9b8e290f7b5 / ext3 relatime,errors=remount-ro 0 1
# /dev/sda5
UUID=404f5e34-153f-4ce7-aa8a-c811533d3620 none swap sw 0 0
/dev/sdb1 /media/storage1 auto umask=000 0 1
/dev/sdb3 /media/storage3 auto umask=000 0 1
/dev/sdb6 /media/storage6 ext3 defaults,users 0 1
/dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

I should mention that even thought I have totally changed this discs configuration, I stil gte this error. The only clue I can offer is that this error is never corrected by rebooting. But often corrected by a full shutdown and then starting. Do others have the same behaviour?

Also we need to change the description of this bug to reflect that it's not just on USB mounted drives.

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

I read about using fsck to repair the superblock, so I unmounted /dev/sdb and got this:

duncan@duncan-desktop:~$ sudo fsck -r -t ext3 /dev/sdb
fsck 1.40.8 (13-Mar-2008)
e2fsck 1.40.8 (13-Mar-2008)
fsck.ext3: Superblock invalid, trying backup blocks...
fsck.ext3: Bad magic number in super-block while trying to open /dev/sdb

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>

That didn't help so I've created question #42774

Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :
Revision history for this message
Brian Murray (brian-murray) wrote :

Device assignments, /dev/[hs]d*, can change between boots and kernel versions, and that is why UUIDs are recommended to be used /etc/fstab. You can learn more about using UUID at https://help.ubuntu.com/community/UsingUUID .

Revision history for this message
rupert (r-plumridge) wrote :

I had a similiar problem too. It turned out to be similiar to the solutions mentioned above, where my /etc/fstab file was using /dev/sdXX to refer to a drive, rather than a UUID number. However, in the past, for some reason the UUID number for a particular USB drive just didn't work, so I was forced to use /dev/sdXX. It seems this problem is now fixed with the recent Ubuntu 8.04 updates (the version I am using) and using UUID numbers for all my drives in /etc/fstab fixed the error posted by the original poster (the fsck died with exit code 8).

What I was wondering though, wouldn't it be better if fsck didn't use /etc/fstab at all? Since it runs with the drives unmounted, it doesn't need /etc/fstab. Can it not work out what the drives are (i.e. filesystem type) by itself? This would mean you don't get fsck errors if /etc/fstab is wrong..just a thought.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.