Installation generated /etc/fstab while relying on UUID leaves wrong device file names in comments
Bug #159851 reported by
Gatestone
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
partman-target (Ubuntu) |
Fix Released
|
Undecided
|
Colin Watson |
Bug Description
While the UUID based system works nicely (except for swap devices, as noted in other bug reports) it leaves static and possibly wrong partition device file names in comments.
I installed on my "modular bay" 2nd hard disk in my laptop, while the 1st internal disk was removed, just for sure, to not destroy my Windows or MBR there. Maybe it was /dev/sda at that time, while it was the only disk? Anyway, after re-inserting the 1st disk and booting from the 2nd disk it is now /dev/sdb, and the UUID based mount work nicely. But the comments remain /dev/sda? which may be very confusing for people, since you really rely on those comments, when you can not really read much info from the UUIDs
To post a comment you must log in.
We can't easily keep the comments up-to-date; the device names could potentially change frequently, especially when removable disks are involved.
However, the comments were unnecessarily brief, and this was definitely a problem. As of Jaunty, instead of simply "# /dev/sda1", you'll get "# / was on /dev/sda1 during installation". I hope this helps to resolve the confusion. There's also now a comment at the top of the file as follows:
# Use 'vol_id --uuid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
partman-target (58ubuntu2) jaunty; urgency=low
* /media must be on the root file system (although subdirectories may be
mounted separately), since the installer relies on being able to mount
things like /media/cdrom during installation. Check this (LP: #16871).
* Expand comment above each UUID-mounted partition, based on a suggestion
by Daniel Pocock in Debian #509378.
* Add a note about 'vol_id --uuid' to the top of /etc/fstab; thanks to
Chris Cheney for the suggestion (LP: #221474).
-- Colin Watson <email address hidden> Tue, 06 Jan 2009 17:18:06 +0000