Solved After restart /dev disk name change

Solved issue

solidsnake

Member
Joined
Oct 6, 2021
Messages
44
Reaction score
2
Credits
592
before restart
/pata1 --> mounted with dev/sda1.
/pata2 --> mounted dev/sdb1

After restarting my server, I mounted the disks as follows


/pata1 --> mounted with dev/sdb1.
/pata2 --> mounted dev/sda1

If I specify these disks with their wwid in fstab, can I solve this problem?
 


Yes, this is common in Linux.
It is recommended not to use device paths.

instead of /dev/sda1 and /dev/sdb1

type this command

blkid /dev/sda1

blkid /dev/sdb1


Put these lines in your /etc/fstab


UUID=34574c75-6b00-4b96-83a2-beeddecd28b3 /pata1 ext4 defaults 0 0
UUID=8b9f07b0-8c34-4679-afe3-c55949039db0 /pata2 ext4 defaults 0 0

Obviously your UUID's will be different, use the ones from the blkid command.

If you're not using ext4, change the filesystem type to whatever you're using.
 
Yes, this is common in Linux.
It is recommended not to use device paths.

instead of /dev/sda1 and /dev/sdb1

type this command

blkid /dev/sda1

blkid /dev/sdb1


Put these lines in your /etc/fstab


UUID=34574c75-6b00-4b96-83a2-beeddecd28b3 /pata1 ext4 defaults 0 0
UUID=8b9f07b0-8c34-4679-afe3-c55949039db0 /pata2 ext4 defaults 0 0

Obviously your UUID's will be different, use the ones from the blkid command.

If you're not using ext4, change the filesystem type to whatever you're using.
Does this cause a problem on reboot?
 

Members online


Top