The /etc/fstab is automatically mounted to the Linux file system at boot time.
The data items that are/etc/fstab in Linux are as follows:
/dev/device mountpoint type rules 0 order
例如这是一个普通的/etc/fstab:
/dev/hda2 / ext3 defaults 0 1
/dev/hda3 swap swap defaults 0 0
/dev/hda5 /usr ext3 defaults 0 0
/dev/fdo /mnt/flopy ext3 noauto 0 0
#开机不自动挂载
/dev/cdrom /mnt/cdrom iso9660 noauto,ro 0 0
- #开机自动挂载
#/dev/cdrom /mnt/cdrom iso9660 noauto,ro 0 0
- /dev/device: devices that require mounting
- Mountpoint: Mount point.
- Type: File System class shape.
- Rules are those that are attached to a mount. Here are a few common examples:
Auto-mount automatic boot Default sets the mount definition according to the default values of most permanent file systems noauto Boot does not mount automatically Nouser only super users can mount ro Mount by read-only permission RW mount by Read writable permission user can mount
Please noteThe optical drive and floppy drive can be mounted only when the media is installed, so it is Noauto
- 0 refers to the dump (System Backup utility). This entry is 0, which means that you never back up. If you last backed up with a dump, the number of days since backup is displayed.
- Order refers to fsck (the order in which fsck checks at startup). 0 means no check, the (/) partition is always 1, the other partitions can only start at 2, and when the numbers are the same check (but not 21).
After modifying the/etc/fstab, be sure to reboot the system before it is valid.
From for notes (Wiz)
Automatic mount CDRom and fstab file contents detailed