Would switching to AHCI mode change my /dev ID's?

Status
Not open for further replies.

Jayce

Fully Optimized
Messages
3,056
Location
/home/jason
I have 4 hard drives.

sda = 500gb Main
sdb = 250gb Samba
sdc = 500gb Main Backup
sdd = 250gb Samba Backup

I originally ran Ubuntu in AHCI mode, but thanks to Vista locking up my computer with hibernation, I had to reset the CMOS battery in order to get it to power on. As a result, it changed to Legacy IDE by default. SO... I switched to AHCI mode, and I realized my drives changed. Now it's...

sda = 500 Main
sdb = 500 Main Backup
sdc = 250 Samba
sdd = 250 Samba Backup

I noticed this when my backup drive for the samba network (the first 250gb drive, which was originally on sdb) was copying data over it shouldn't have. I noticed it had taken on a different device ID.

Would switching to AHCI mode have caused this? Cause uh, that's all I changed... I'm glad I caught it, otherwise I would have had some problems recovering my data!
 
All right, ignore all that garbage. I forgot that I switched 2 SATA cables on my hard drives, which after more reading I concluded that the device ID can be changed depending on where the drives are plugged in. So that answers my question.

New question, though. Instead of assigning device ID's to my backup rsync script, I decided to go with UUID's due to the fact they seem to be more reliable in terms of them staying the same and never changing, unlike the device ID's.

So, to start I went to /etc/fstab to add the other drives to the list. I don't know what the variables are here, so I hope somebody can explain this to me.

But I went to terminal and typed blkid, which gave me the UUID for the 3 drives I needed. Okay, fine. So I went to fstab and pasted them over.

#/dev/sdb1
UUID=b2354e40-cd24-41eb-b41b-0aadc9933166 /media/localbackup ext3 defaults 0 0

#/dev/sdc1
UUID=772764b7-e571-4897-ba6d-ded412a5e814 /media/storage ext3 defaults 0 0

#/dev/sdd1
UUID=b862f78f-4fcc-4d41-9d64-b7534da2dc84 /media/storagebackup ext3 defaults 0 0


Before, I had 0 1 and it didn't work. I changed it to 0 0 and it works. Why? What do those variables do?

Nonetheless, it seems pretty easy to set up. Just had to blkid, get the UUID, paste in /etc/fstab in a logical manner (I basically compared the format to existing entries within fstab) and bam.... auto mount for those drives worked for me! But like I said, I'm curious as to what those 0 1 and 0 0 do.
 
Status
Not open for further replies.
Back
Top Bottom