Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am using Debian 7 with two HDDs: 500Gb PATA and 750Gb SATA.

blkid shows me the following:

root@intel:/etc# blkid
/dev/sda1: UUID="b6350c6b-5fbd-4e07-9a4b-10b600fbb64c" TYPE="swap" 
/dev/sda2: UUID="2f852e13-38ee-4b56-a474-d675c22d5f28" TYPE="ext4" 
/dev/sda3: UUID="78e34fe3-365c-4c4d-86b8-51615641f9ec" TYPE="ext4" 
/dev/sdb1: LABEL="data" UUID="03c3f01f-d390-49de-a570-3de4b73a9fea" TYPE="ext4"

content of fstab:

root@intel:/etc# cat /etc/fstab
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
# / was on /dev/sda2 during installation
UUID=2f852e13-38ee-4b56-a474-d675c22d5f28    /               ext4    errors=remount-ro  0       1
# /home was on /dev/sda3 during installation
UUID=78e34fe3-365c-4c4d-86b8-51615641f9ec    /home           ext4    defaults       0       2
# /data was on /dev/sdb1
UUID=b6350c6b-5fbd-4e07-9a4b-10b600fbb64c    /data       ext4    defaults       0   2
# swap was on /dev/sda1 during installation
UUID=03c3f01f-d390-49de-a570-3de4b73a9fea    none            swap    sw         0       0
/dev/sr0        /media/cdrom0   udf,iso9660 user,noauto     0       0

System can't boot until I comment out /dev/sdb1. The fsck fails to check filesystem:

root@intel:/etc# fsck /dev/sdb1
fsck from util-linux 2.20.1
fsck: fsck.swap: not found
fsck: error 2 while executing fsck.swap for /dev/sdb1

but after boot with commented

# /data was on /dev/sdb1
UUID=b6350c6b-5fbd-4e07-9a4b-10b600fbb64c    /data       ext4    defaults       0   2

line of fstab I can mount /dev/sdb1.

The only one question is "What's happening?". Is my 750Gb HDD dying? How can I check /dev/sdb1?

Best regards.

share|improve this question
    
When you say that after boot you can mount /dev/sdb1, could you tell us exactly what command you're using to mount it? –  MadHatter Oct 25 '13 at 11:15
    
mount /dev/sdb1 /mnt works fine. –  gooamoko Oct 25 '13 at 11:33

2 Answers 2

up vote 1 down vote accepted

Your blkid shows that /dev/sdb1 is an ext4 filesystem (and by you trying to mount it, suggests it is) however, your fstab disagrees:

# swap was on /dev/sda1 during installation
UUID=03c3f01f-d390-49de-a570-3de4b73a9fea    none            swap    sw         0       0

And your UUID matches /dev/sdb1 as you showed with blkid:

/dev/sdb1: LABEL="data" UUID="03c3f01f-d390-49de-a570-3de4b73a9fea" TYPE="ext4"

During boot, it is trying to use /dev/sdb1 as it's swap partition and does an fsck.swap /dev/sdb1 which fails since it's not a swap partition.

You should be able to fsck it with fsck.ext4 /dev/sdb1 and you'll need to edit your fstab to reflect the REAL swap parition's uuid.

It appears you just have your two UUIDs switched around:

UUID=b6350c6b-5fbd-4e07-9a4b-10b600fbb64c    /data       ext4    defaults       0   2
UUID=03c3f01f-d390-49de-a570-3de4b73a9fea    none            swap    sw         0       0

vs

/dev/sda1: UUID="b6350c6b-5fbd-4e07-9a4b-10b600fbb64c" TYPE="swap" 
/dev/sdb1: UUID="03c3f01f-d390-49de-a570-3de4b73a9fea" TYPE="ext4"
share|improve this answer
    
Yep. I found it too just after writing a question. But I don't know why it's happened. Thank you for your answer. –  gooamoko Oct 25 '13 at 11:31

Check your partition table with cfdisk or similar tool. Chances are the partition type of /dev/sdb1 is set to "Linux swap" instead of "Linux".

In order to check the partition directly, call e4fsck /dev/sdb1.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.