Bug 557831 - blkid detects ext4 fs as minix fs
Summary: blkid detects ext4 fs as minix fs
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: util-linux-ng
Version: 12
Hardware: All
OS: Linux
low
high
Target Milestone: ---
Assignee: Karel Zak
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-01-22 17:14 UTC by Danny Baumann
Modified: 2010-02-20 00:18 UTC (History)
1 user (show)

Fixed In Version: util-linux-ng-2.16.2-6.fc12
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-02-20 00:18:29 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Copy of the wrongly detected superblock (4.00 KB, application/octet-stream)
2010-01-22 17:14 UTC, Danny Baumann
no flags Details
Superblock after successful boot (4.00 KB, application/octet-stream)
2010-01-22 17:15 UTC, Danny Baumann
no flags Details

Description Danny Baumann 2010-01-22 17:14:32 UTC
Created attachment 386198 [details]
Copy of the wrongly detected superblock

Description of problem:
Today, blkid detected my (perfectly valid) ext4 root filesystem also as minix filesystem, thus throwing an error and not determining the filesystem type correctly. As a result, mount could not mount my root filesystem type (complaining that I need to specify the filesystem type), leaving me with an unbootable system.

I will attach a copy of the superblock in the broken as well as in the correct state. One can observe that in the broken case, a minix fs signature (2 bytes only) was detected at offset 0x410, the position of the least two significant bytes of the ext4 free inode count.

A workaround was specifying rootfstype=ext4 on the grub kernel command line, which allowed booting. After that, fortunately a few additional inodes were used, thus I needed that workaround only once ;-)

Still, blkid should use better heuristics and/or additional sanity checks to determine the type of the filesystem, because a root filesystem being unmountable by pure coincidence is not a good thing for the average user, who will probably reinstall his whole system.

Comment 1 Danny Baumann 2010-01-22 17:15:04 UTC
Created attachment 386199 [details]
Superblock after successful boot

Comment 2 Karel Zak 2010-01-27 13:04:58 UTC
Nice catch. Yes, you're right the minix probing code is too simple. It seems that we can also check for a valid number of inodes, zones and blocksize in minix superblock. I'll fix it. Thanks.

Comment 3 Karel Zak 2010-01-27 14:03:43 UTC
Fixed in upstream repository by commit 75cb940e23a852c81044117753222d163bb3355f.

Comment 4 Fedora Update System 2010-02-17 19:36:42 UTC
util-linux-ng-2.16.2-6.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/util-linux-ng-2.16.2-6.fc12

Comment 5 Fedora Update System 2010-02-20 00:18:19 UTC
util-linux-ng-2.16.2-6.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.