Welcome to LQ!
Originally Posted by jehojakim
I am wondering how the naming scheme om SATA-disks is made. At this moment, I have 4 SATA-slots on my MB, SATA1 trough SATA4. SATA1 has /dev/sda, SATA 4 has sdb.
/dev/sda is boot disk.
How is this naming scheme accomplished?
And, related to that, will it still boot from this disk if I attach the disk to another SATA-port on the MB?
One step further, if I set up a RAID-5 with four disks, will I get in trouble if for some reason I swap disks in the RAID-5 configuration?
Thanks for your answers, or for putting me on the track for further searching.
Your boot device is set by selection with your 'BIOS'. Most current distributions use 'udev' to recognize devices for the kernel via defined rules.
excertp from 'man udev';
udev - dynamic device management
udev provides a dynamic device directory containing only the files for
actually present devices. It creates or removes device node files in
the /dev directory, or it renames network interfaces.
Usually udev runs as udevd(8) and receives uevents directly from the
kernel if a device is added or removed from the system.
If udev receives a device event, it matches its configured rules
against the available device attributes provided in sysfs to identify
the device. Rules that match may provide additional device information
or specify a device node name and multiple symlink names and instruct
udev to run additional programs as part of the device event handling.
udev configuration files are placed in /etc/udev/ and /lib/udev/. All
empty lines, or lines beginning with '#' will be ignored.
udev expects its main configuration file at /etc/udev/udev.conf. It
consists of a set of variables allowing the user to override default
udev values. The following variables can be set:
Specifies where to place the device nodes in the filesystem. The
default value is /dev.
The logging priority. Valid values are the numerical syslog
priorities or their textual representations: err, info and debug.
The udev rules are read from the files located in the default rules
directory /lib/udev/rules.d/, the custom rules directory
/etc/udev/rules.d/ and the temporary rules directory
/dev/.udev/rules.d/. All rule files are sorted and processed in lexical
order, regardless in which of these directories they live.
Rule files are required to have a unique name, duplicate file names are
ignored. Files in /etc/udev/rules.d/ have precedence over files with
the same name in /lib/udev/rules.d/. This can be used to ignore a
default rules file if needed.
Every line in the rules file contains at least one key value pair.
There are two kind of keys, match and assignment keys. If all match
keys are matching against its value, the rule gets applied and the
assign keys get the specified value assigned.
A matching rule may specify the name of the device node, add a symlink
pointing to the node, or run a specified program as part of the event
handling. If no matching rule is found, the default device node name is
I suggest that you read the 'man udev'. You can also look at 'Linux Kernel in a Nutshell
' to get some insight.
These links and others can be found at 'Slackware-Links
' . More than just SlackwareŽ links!