freebsd-skq/sbin/newfs
Edward Tomasz Napierala 549f62fa42 Fix problem with geom_label(4) not recognizing UFS labels on filesystems
extended using growfs(8).  The problem here is that geom_label checks if
the filesystem size recorded in UFS superblock is equal to the provider
(i.e. device) size.  This check cannot be removed due to backward
compatibility.  On the other hand, in most cases growfs(8) cannot set
fs_size in the superblock to match the provider size, because, differently
from newfs(8), it cannot recompute cylinder group sizes.

To fix this problem, add another superblock field, fs_providersize, used
only for this purpose.  The geom_label(4) will attach if either fs_size
(filesystem created with newfs(8)) or fs_providersize (filesystem expanded
using growfs(8)) matches the device size.

PR:		kern/165962
Reviewed by:	mckusick
Sponsored by:	FreeBSD Foundation
2012-10-30 21:32:10 +00:00
..
Makefile Use expand_number(3) from libutil instead of home-grown function to parse 2010-03-03 19:25:28 +00:00
mkfs.c Fix problem with geom_label(4) not recognizing UFS labels on filesystems 2012-10-30 21:32:10 +00:00
newfs.8 Advertise growfs(8) a little better. 2011-06-22 18:02:28 +00:00
newfs.c Fix problem with geom_label(4) not recognizing UFS labels on filesystems 2012-10-30 21:32:10 +00:00
newfs.h Fix problem with geom_label(4) not recognizing UFS labels on filesystems 2012-10-30 21:32:10 +00:00
ref.test
runtest00.sh
runtest01.sh