/dev/hda2 | / | ext2 | defaults | 1 | 1 | The first column contains the device name, | |
/dev/hdb1 | /home | ext2 | defaults | 1 | 2 | The second one its mount point, | |
/dev/cdrom | /media/cdrom | auto | ro,noauto,user,exec | 0 | 0 | Third its file system type, | |
/dev/fd0 | /media/floppy | auto | rw,noauto,user,sync | 0 | 0 | Fourth the mount options, | |
proc | /proc | proc | defaults | 0 | 0 | Fifth (a number) dump options, | |
/dev/hda1 | swap | swap | pri=42 | 0 | 0 | Sixth (another number) file system check options. |
ext2, ext3 and ext4 | Linux partitions |
reiserfs | Journaled Linux partitions |
swap | Swap partitions |
vfat and ntfs | Windows partitions |
auto | Detected automatically |
The first and second columns tell the mount command the device or partition, and what is the mount point.
The mount point specified for a device in /etc/fstab is its default mount point.
That is the directory where the device will be mounted if you don't specify any other mount point when mounting the device.
The third column specifies the file system type of the device or partition.
The fourth column lists all the mount options for the device or partition.
The 5th column in /etc/fstab is the dump option. Dump checks it and uses the number to decide if a file system should be backed up. If it's zero, dump will ignore that file system.
The 6th column is a fsck option. fsck looks at the number in the 6th column to determine in which order the file systems should be checked. If it's zero, fsck won't check the file system.
auto / noauto | With the auto option, the device will be mounted automatically. |
user / nouser | The user option allows normal users to mount the device, whereas nouser lets only the root to mount the device. |
exec / noexec | exec lets you execute binaries that are on that partition, whereas noexec doesn't let you do that. |
ro | Mount the file system read-only. |
rw | Mount the file system read-write. |
sync / async | How the input and output to the file system should be done. sync means it's done synchronously, the changes are physically written to the disk at the same time you issue the copy command. |
defaults | Uses the default options that are rw, suid, dev, exec, auto, nouser, and async. |