1

I have a disk

sudo lshw -C disk

 *-disk
   description: ATA Disk
   product: Corsair CSSD-F12
   physical id: 0.0.0
   bus info: scsi@7:0.0.0
   logical name: /dev/sde
   version: 2.0
   serial: 10516505330003430015
   size: 111GiB (120GB)
   capabilities: gpt-1.00 partitioned partitioned:gpt
   configuration: ansiversion=5 guid=21ec30ba-0aab-4ce9-be03-8f6f4de1afa1 sectorsize=512

I've mounted it yesterday: cat /etc/fstab

/dev/sdg1 /home/ssa/mnt/corsair ext4 defaults 0 0

Yesterday it had path /dev/sdg1 now it's /dev/sde and mount is not working. Why name is changed after reboot?

4

Such device names are not persistent, udev makes no guarantees that they will be the same. The Arch Wiki says:

Because udev loads all modules asynchronously, they are initialized in a different order. This can result in devices randomly switching names. A udev rule can be added to use static device names.

You should use labels or UUIDs instead.

First, get the UUID:

sudo blkid -o export /path/to/device | grep UUID

Then use:

UUID=... /path/to/mount/point type ...

For example:

$ sudo blkid -o export /dev/sda3 | grep UUID
UUID=d3504dc2-8f01-48f1-be05-d265110e2e73

And the corresponding entry would be:

UUID=d3504dc2-8f01-48f1-be05-d265110e2e73 /   ext4    errors=remount-ro 0       1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.