Differences between revisions 33 and 34
Revision 33 as of 2020-03-14 19:29:22
Size: 3151
Comment: moved current info before Lenny, minor fixes
Revision 34 as of 2020-03-15 00:33:54
Size: 3117
Editor: PaulWise
Comment: general clean up
Deletions are marked like this. Additions are marked like this.
Line 5: Line 5:
Line 6: Line 7:
The disk naming has changed in recent versions of Debian. Today (e.g. in Stretch) all disks - no matter if (S)ATA or SCSI - are called {{{/dev/sda}}}, {{{/dev/sdb}}} and so on. It seems to be like this because the `libata` library emulates an SCSI disk for each ATA disk.
Line 8: Line 8:
It is still posible to influence the naming by the use of `udev` rules, see below. The disk naming has changed in recent versions of Debian. Today (since stretch) all (S)ATA and SCSI disks are called {{{/dev/sda}}}, {{{/dev/sdb}}} and so on. It seems to be like this because the `libata` library emulates an SCSI disk for each ATA disk.

It is still possible to influence the naming by the use of `udev` rules, see below.
Line 11: Line 13:
Line 34: Line 37:
Line 40: Line 44:
Line 43: Line 48:
Line 47: Line 53:
 * [[Partition]] , [[NAS]] , [[SATA]]  * [[Partition]], [[NAS]], [[SATA]]
Line 50: Line 56:
Line 57: Line 64:
 * [[DebianMan:8/hdparm|hdparm(8)]] manual page, in Debian from Stretch 2017  * [[DebianMan:8/hdparm|hdparm(8)]] manual page

Translation(s): English - Français - Italiano - Brazilian Portuguese - Русский

Hard disk device name

In current Debian versions

The disk naming has changed in recent versions of Debian. Today (since stretch) all (S)ATA and SCSI disks are called /dev/sda, /dev/sdb and so on. It seems to be like this because the libata library emulates an SCSI disk for each ATA disk.

It is still possible to influence the naming by the use of udev rules, see below.

In Debian Lenny

The disks are named according to rules defined in /etc/udev/rules.d

The default udev rules define the following naming:

If you have IDE Hard disks:

 /dev/hda is IDE primary master (equivalent to c: in Windows)
 /dev/hdb is IDE primary slave (equivalent to d: and so on)

The exception is if you have a CDROM or DVDROMs attached to the first IDE controller, those could be named as /dev/hda.

If your hard disk is attached to a second IDE controller, it will be named /dev/hdc or /dev/hdd as follows:

 /dev/hdc is IDE secondary master
 /dev/hdd is IDE secondary slave

Nowadays, with SATA controllers, the drive may be named as /dev/hde, /dev/hdf etc. Sometimes the IDE disks are /dev/sda (eg SiI RAID capable controller).

If you have SCSI hard disks, Linux names them as /dev/sda, /dev/sdb etc.

Influence hard disk naming

Disk naming is done by udev.

You can define udev rules of your own to achieve completely different naming, for example persistent disk names according to disk bay position.

Working with drive parameters

hdparm is a tool for query and adjustment of settings for SATA and IDE drives. For example you can define the idle time after which a hard disk switches off the motor.

Testing a Harddisk

See also

References

Hard disk naming

Udev

Hdparm


CategoryHardware | CategoryStorage