- Mounting and Unmounting.
- A Linux file system is constructed of storage on many devices.
- Use df to see what's there (or df -h).
- Many of these are "virtual" file systems.
- Look for the real device names, like /dev/sda3
- Red-Hat based systems often have /dev/mapper/whatever, which
represent storage pools.
- The /etc/fstab lists the volumes.
- Each entry maps a device to a file system location.
- Devices are traditionally named by hardware path in /dev.
- Now often named by LABEL or UUID (blkid, tune2fs).
- Volumes can be added or removed from the fs using the
mount and umount commands.
- On current systems, this is done automatically.
- The hideously complicated udev system handles various events.
- It executes mounts and umount when devices are plugged in and removed.
- Servers often use explicit mounts.
- Formatting a volume.
- Physical devices are divided into partitions.
- The partitions on a disk are recorded in a partition table, usually
at the start of the physical volume.
- Manipulate PT with fdisk.
- Legacy PC partitioning is MBR (Master Boot Record).
Still seems most common.
- Newer one seems to be GPT (GUID Partition Table), which has fewer
- There are others.
- File systems are built inside partitions,
- The fsck program verifies the condition of a file system.
- In the past, commonly run when the system is booted after a crash.
Fixes OS problems.
- Now used more rarely.
- Book mentions floppy drives.
- Raw copies
- The dd command is used to copy raw volumes.
- Copies a file system, not the files.
- Often has been used to copy disk images to volumes.
- Clone a drive.
- Creating a CDROM
- Creating an image. mkisofs or genisoimage
genisoimage -o imagefile.iso -R -J directory
- Can mount the image with mount -o loop imagefile.iso /mnt/tmp
- Writing the image to disk wodim.
wodim imagefile.iso, or wodim dev=/dev/cdrw imagefile.iso.