Results 1 to 5 of 5
Xubuntu 8.04.
Started on a box with IDE CD and one SATA disk (slot 1). Then added another (slot 2). All OK: /dev/sda and /dev/sdb. Now tried to add a ...
- 05-25-2009 #1Just Joined!
- Join Date
- May 2009
- Location
- Riga, Latvia
- Posts
- 2
3rd SATA disk becomes the first?
Xubuntu 8.04.
Started on a box with IDE CD and one SATA disk (slot 1). Then added another (slot 2). All OK: /dev/sda and /dev/sdb. Now tried to add a 3rd one - taken from a broken Windows box (tried both spare slots: 3 and 4).
The system boots all right - except now /dev/sda is this new disk. Former sda becomes sdb, and former sdb becomes sdc (so all the links are lost and the 2nd disk is not automounted at all). System boots from sdb nevertheless and shows no warning (graphical mode w/o details).
Removing the 3rd drive sets the things back old way.
New to Ubuntu and not that much familiar with Debian (mostly RH and clones so far), so i need advice.
TIA
- 05-25-2009 #2
Use uuid for partition identification, that way it does not matter if partition is sda1 sdb1 or sdc1. Use ls /dev/disk/by-uuid -l to match partition and uuid. You can edit fstab directly or you can do something like
then edit to suit usingCode:cat /etc/fstab > new_fstab ls /dev/disk/by-uuid -l >> new_fstab
once you have all info correct useCode:nano new_fstab
If you need more help with this then use the first 2 commands and then post contents of new_fstab here.Code:sudo mv /etc/fstab /etc/fstab.old sudo mv new_fstab /etc/fstab
- 06-03-2009 #3Just Joined!
- Join Date
- May 2009
- Location
- Riga, Latvia
- Posts
- 2
Sorry for delay and thanks for advice. I managed to do that (i.e. to set things more or less right with UUID). Altogether, why the 3rd slot has come forth, is still a puzzle for me

Thanks once more.
- 06-03-2009 #4Just Joined!
- Join Date
- May 2009
- Posts
- 15
Basically it's a bus logic thing that maps according to a first come first serve method. With out using labels or the UUID for your drives to exactly identify and map your drives, the HAL/UDEV will assign /dev/sda to the first bus to come up.
Generally, if you have IDE0 IDE1 IDE2, during boot it should come up in order as IDE0 then IDE1 then IDE2... however it is entirely possible that IDE2 comes up before IDE0 and IDE1. In a first come first serve method IDE2 will be mapped to /dev/sda in the instance that it comes up before IDE0 and IDE1.
I'm still new, too... so I hope my explanation doesn't confuse you even more
- 06-06-2009 #5Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 8,975
I usually label my drives and mount them using the labels instead of the device id (/dev/sdxN). That way, if the OS changes the id because of this sort of issue, it will still mount correctly. Example from my fstab:
LABEL=afs-esata-1 /mnt/esata1 ext3 defaults 1 2
You can add a label to an existing ext2/ext3 file system with the command: mkfs -L <name> /dev/sdxN
Example: mkfs -L /boot1 /dev/sda1 ; mkfs -L SWAP-sda2 /dev/sda2 ; mkfs -L / /dev/sda3
Now, you can change your /etc/fstab to mount /, /boot and swap this way:Now, if the system ever changes the partition or drive order, it will continue to boot properly.Code:LABEL=/ / ext3 defaults 1 1 LABEL=/boot1 /boot ext3 defaults 1 2 LABEL=SWAP-sda2 swap swap defaults 0 0
Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!


Reply With Quote