Whamcloud - gitweb
misc: remove broken whole device check
authorRichard Yao <richard.yao@clusterhq.com>
Sun, 14 Jun 2015 18:50:53 +0000 (14:50 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 14 Jun 2015 18:50:58 +0000 (14:50 -0400)
commit97e9b970769b1afe462f82390cb5876cf037b903
tree3bc08eb6bc9f967a12bd6a0510fe3af9157d4def
parent58354a38e218baeb89fbaa4d9b27e2c948e08332
misc: remove broken whole device check

Modern Linux major/minor numbering on block devices no longer conform to
the divisible by 64 rule for minor numbering. On my development system,
the correct number is 16. Consequently, this applies only to every 4th
drive on a modern system, which is inconsistent. That caused the
following bug to be filed against Flocker:

https://clusterhq.atlassian.net/browse/FLOC-2041

We could unconditionally pass -F to override this check whenever it
triggers, but that it would also override the libblkid check that
determines whether there are existing partitions, logical volumes or
filesystems on the disk, which seems unwise.

I propose that this check be removed because passing a whole disk to
mke2fs is a valid use case and given how long this has been broken,
users are already accustomed to the behavior where -F is not necessary
to format a whole disk as ext4.

Signed-off-by: Richard Yao <ryao@gentoo.org>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Andreas Dilger <adilger@dilger.ca>
misc/plausible.c