The format of the fstab
file is documented in the fstab(5)
man page. The fifth column indicates whether the filesystem should be dumped; unless you know what this means, put 0
. The sixth column indicates whether to check the filesystem at boot time; specify 1
for the root partition, 2
for all other internal filesystems, and 0
for external drives and filesystems from other operating systems. If the fifth and sixth columns contain zeroes, you don't need to put them (i.e. just put the first four columns).
The fourth column lists mount options; they differ to some extent from filesystem to filesystem, and they are documented in the mount(8)
manual page. If you have no mount options, put defaults
. Don't change the defaults put by the distribution unless you understand what you're doing. Common combinations of options are:
user,noauto
or user,noauto,exec
for filesystems that are not mounted automatically at boot time and anyone can mount explicitly.
acl,errors=remount,ro
for ext2/ext3/ext4 filesystems with ACLs enabled; this is a common setting for OS filesystems.
nodev,nosuid
for NFS filesystems.
nodev
and nosuid
add security at the expense of functionality: they forbid device files and setuid/setgid executables respectively. They're mostly useful when mounting foreign filesystems whose root user you don't trust. For a /home
filesystem that's on a different partition of your local disk, they're not really useful, but the functionality they disable is unlikely to be useful (especially for nodev
; setxid programs can be useful on /home
occasionally).
man fstab
. And if you are new to linux, do not change them. It is hardly ever the right thing to do. – rozcietrzewiacz Jul 31 '11 at 00:52