LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   /dev/sda & /dev/sdb keeps swapping name (https://www.linuxquestions.org/questions/linux-hardware-18/dev-sda-and-dev-sdb-keeps-swapping-name-621347/)

sinister1 02-15-2008 07:56 AM

/dev/sda & /dev/sdb keeps swapping name
 
Hi,

I have a problem with my raid config.

I have a storage of 367 GB which it is mounted as /dev/sdb but this is different after every boot.

It starts as /dev/sdb.

Reboot

it starts as /dev/sda

Reboot

it start as /dev/sdb

etc...

THE CONFIG of FDISK -L

Disk /dev/sda: 9180 MB, 9180515328 bytes
255 heads, 63 sectors/track, 1116 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x0009000d

Device Boot Start End Blocks Id System
/dev/sda1 * 1 1062 8530483+ 83 Linux
/dev/sda2 1063 1116 433755 5 Extended
/dev/sda5 1063 1116 433723+ 82 Linux swap / Solaris

Disk /dev/sdb: 367.0 GB, 367033057280 bytes
255 heads, 63 sectors/track, 44622 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/sdb1 1 44622 358426183+ 83 Linux





What have i done so far:

changed the cables
changed the raid card
changed the raid config
cleared the config and configed it again
deleted the partition and made a partition again

any ideas?

michaelk 02-15-2008 11:05 AM

What type of drives are these? SATA, SCSI etc.
What linux distribution/version are you running?

David the H. 02-15-2008 11:08 AM

In /dev/disk/* you'll find links to each disk device on your system, named according to things like the drive's serial number or label. Use these in your configuration files instead of /dev/sd* and you'll always get the same devices regardless of the order in which the system detects them.

michaelk 02-15-2008 11:26 AM

To elaborate on David the H's post google and read the mount man pages for UUID and volume labels.

sinister1 02-18-2008 01:44 AM

Oke thanks.

There is only one thing i dont get:

my fstab:

# /dev/sda1
UUID=9940c6fc-b36a-4ef5-9e36-e959aa20eb51 / ext3 defaults,errors=remount-ro 0 1
# /dev/sda5
UUID=3703e4c5-c189-4892-a0f7-b230dd941797 none swap sw 0 0

But sometimes sda1 becomes sdb1 after reboot. If i look at my fstab and see that i use the uuid to mount the main disk shouldn't it always become sda?

Thanks for the reply!


All times are GMT -5. The time now is 10:32 AM.