How It Works - Red Hat ENTERPRISE LINUX 3 System Administration Manual

Hide thumbs Also See for ENTERPRISE LINUX 3:
Table of Contents

Advertisement

Chapter 7. User-Defined Device Names
This commands adds an entry for the mount point to
symbolic link from
/dev/usbcard
that the device should be automatically mounted when
in
and if the device exists (a device with the same UUID is found).
/etc/fstab
The
is a program that scans the IDE and SCSI buses for new devices and adds entries to
updfstab
for them if entries do not already exist. It also adds entries for USB devices since they
/etc/fstab
appear as SCSI devices. Refer to the
When a USB device is inserted,
for the storage device (such as the media card) if it exists. (If a card reader without
/etc/fstab
a card in it is inserted, an entry is not added.) The line added contains the actual device name (such
as
) and the
/dev/sda1
the device does not exist. Since the line is required by
so the line remains in the file. Also change the device name to the
) and create the mount point (such as
/dev/usbcard
After modifying the line, it should look similar to the following:
/dev/usbcard
/mnt/usbcard
Because of
--automount
device is mounted in
that when the USB card reader is plugged into the computer, the card must already be in the reader. If
not,
can not find the storage device, and thus it can not automatically mount it.
devlabel
If the USB card reader is already plugged in without a card, when the card is inserted, run the com-
mand
restart
devlabel

7.2. How It Works

The command
devlabel restart
booted as well as by the appropriate scripts in the
The
option to
restart
(
/etc/sysconfig/devlabel
in its former location, such as
the new location of the disk based on the disk's UUID. If a disk with the same UUID is found, the
symbolic link is updated to point to the new location of the drive, the configuration file is updated
with the new location, and a message similar to the following is displayed:
Device name incorrectly detected for symlink /dev/work!
The device /dev/hdb1 is now /dev/hdd1.
The symlink /dev/work will now point to the new device name.
If a disk with the UUID is not found (for example, the disk was removed), the following is displayed:
The device /dev/hdb1 no longer seems to exist. Because of this, the
symlink /dev/work -> /dev/hdb1 will not be available. The reference
to this symlink in /etc/sysconfig/devlabel will be ignored.
The entry for the device is not removed from the configuration file; it is just ignored for this instance.
1. Kudzu is a hardware probing tool run at system boot time to determine what hardware has been added or
removed from the system.
to
/dev/sda1
updfstab
hotplug
option. The
kudzu
auto
, when
devlabel
when the USB device is plugged into the computer. The trick is
/mnt/usbcard
as root to mount the media card.
is called from the
devlabel
) and follows the symbolic links to determine if the device still exists
/dev/hdb1
/etc/sysconfig/devlabel
. The
--automount
devlabel
man page for more information.
runs the
updfstab
option tells Kudzu
kudzu
devlabel
/mnt/usbcard
noauto,owner 0 0
is restarted, the storage media in the USB card reader
/etc/rc.sysinit
/etc/hotplug/
reads the list of devices in the configuration file
. If the symbolic link is invalid, an attempt is made to find
option to
devlabel
restarts if an entry for it is located
program, which adds an entry to
that it can remove the line if
1
, the
option must be removed
kudzu
device name (such as
devlabel
).
script when the system is
directory.
29
and creates a
specifies

Advertisement

Table of Contents
loading

Table of Contents