llamafilm Posted December 13, 2016 Share Posted December 13, 2016 Since I frequently make changes to my EFI partition, I made a hotkey to run a Terminal command like "diskutil mount disk1s1". But I have several boot disks in this machine, and the disk number isn't always guaranteed to be the same. So I thought it would make sense to use the UUID instead. But I was quite surprised to find that the UUID is not unique! Right now, I have 14 GPT disks connected, and all of them use the same UUID for their EFI partition. Why is this, and is there any other way to uniquely identify a partition? I'm running Yosemite 10.10.5. Link to comment Share on other sites More sharing options...
smolderas Posted December 13, 2016 Share Posted December 13, 2016 Funny I have two EFI partitions from 7 drives that have the same UUID. I'm using following snippet to mount my EFI partition of the current boot volume: mountEFI() { efiPartition=`diskutil list|grep "Recovery HD"|awk '{print "/dev/"substr($7,0,6)"1"; exit}'` sudo mkdir -p /Volumes/EFI && sudo mount -t msdos $efiPartition /Volumes/EFI } Link to comment Share on other sites More sharing options...
llamafilm Posted December 13, 2016 Author Share Posted December 13, 2016 Nice code. But that doesn't work when you have more than one bootable OSX drive. Solved! Disk Utility shows the volume UUID, which for some reason is the same on all EFI partitions, even on other macs. I wonder what the purpose of that is. With command-line diskutil, you can get the partition UUID, which is truly unique, and mount it that way. Link to comment Share on other sites More sharing options...
Recommended Posts