GUID filesystem+device identification ?
Hi all,
Has anybody yet thought about the possibility to use
a mechanism like devfs for identifying devices and file systems by their GUID? This would be a major improvement over Linux's current approach of identifying devices, particularly disk drives.
In principle, it would be possible to change controllers and disks arbitrarily and still maintain a valid file system in which all devices and sub-file systems would be identified by ther GUIDs (think of the device in fstab specified by GUID instead of /dev/sda3 or whatever).
I think something like this could well coexist with devfs in its current implementation, e.g. by a collection of softlinks , something like
/dev/guid/disk/[DISK_GUID]->/dev/scsi/host1/bus0/target2/lun0 /dev/guid/partitions/[PARTITION_GUID]->(you guess).
where these links would be auto-generated when a driver encounters a disk and and the partition table is analyzed.
Links for other devices could of course also exist in /dev/guid, although I think disks and parttions give most benefit.
The approach above would allow entries like
/dev/[PARTITION_GUID] /usr ext2 defaults 2 1
in fstab, so no need to change fstab if controllers or disks are added/removed in a system.
Unlike the "filesystem label" approach, this would work with any filesystem type, and even for entire disks and other devices.
Is anybody working on something like this, or does it even exist already?
If no, what is your opinion on its usefulness?
Regards,
Martin
Signature · 2 lines
Martin Wilck <[email protected]> FSC EP PS DS1, Paderborn Tel. +49 5251 8 15113
Quoted 8 lines · Martin Wilck
Hi all,
Has anybody yet thought about the possibility to use
a mechanism like devfs for identifying devices and file systems by their GUID? This would be a major improvement over Linux's current approach of identifying devices, particularly disk drives.
Quoted 5 lines
In principle, it would be possible to change controllers and disks arbitrarily and still maintain a valid file system in which all devices and sub-file systems would be identified by ther GUIDs (think of the device in fstab specified by GUID instead of
/dev/sda3or whatever).
I think support for GUID=foo in /etc/fstab for mount would be pretty easy. Having it in ther kernel would be nicer and shouldn't be that difficult, on the other hand it'll need a consensus on wether the kernel should look at every partition on startup - IIRC some people where opposed to such soloutions in the past.
Christoph
Signature · 1 line
Of course it doesn't work. We've performed a software upgrade.
Quoted 5 lines
Having it in ther kernel would be nicer and shouldn't be that difficult, on the other hand it'll need a consensus on wether the kernel should look at every partition on startup - IIRC some people where opposed to such soloutions in the past.
The kernel looks at partition type GUID of all partitions already (in fs/partitions/efi.c), all it would need to do apart from that look at the Unique GUID as well and create a GUID->device table somewhere.
Cheers, Martin
Signature · 2 lines
Martin Wilck <[email protected]> FSC EP PS DS1, Paderborn Tel. +49 5251 8 15113