Package: e2fsprogs
Version: 1.42.5-1.1+deb7u1

The subject mostly covers the issue.  Output from a series of commands:

# dd if=/dev/zero of=/tmp/fsimage count=8192
# losetup /dev/loop0 /tmp/fsimage
# mkfs -t ext3 -L areallyreallyreallylonglabelfordemonstration /dev/loop0
mke2fs 1.42.5 (29-Jul-2012)
Filesystem label=areallyreallyrea
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
Stride=0 blocks, Stripe width=0 blocks
1024 inodes, 4096 blocks
204 blocks (4.98%) reserved for the super user
First data block=1
Maximum filesystem blocks=4194304
1 block group
8192 blocks per group, 8192 fragments per group
1024 inodes per group

Allocating group tables: done                            
Writing inode tables: done                            
Creating journal (1024 blocks): done
Writing superblocks and filesystem accounting information: done

# echo $?
0
# tune2fs -L areallyreallyreallylonglabelfordemonstration /dev/loop0
tune2fs 1.42.5 (29-Jul-2012)
Warning: label too long, truncating.
# echo $?
0
# 

mke2fs is hinting at the issue, mainly the line "Filesystem
label=areallyreallyrea", but this warning is quite easy to overlook.  If
one puts the line "LABEL=areallyreallyreallylonglabelfordemonstration"
in /etc/fstab, the mount will fail at boot time and the system could be
troublesome to fix.

I would suggest `mke2fs` should give an error if it truncates the label.
`tune2fs` should also consider giving an error for this situation.


-- 
(\___(\___(\______          --=> 8-) EHM <=--          ______/)___/)___/)
 \BS (    |         [email protected]  PGP 87145445         |    )   /
  \_CS\   |  _____  -O #include <stddisclaimer.h> O-   _____  |   /  _/
8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to