/etc/fstab: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
 
(3 intermediate revisions by the same user not shown)
Line 17: Line 17:
sysfs                                    /sys              sysfs  defaults        0 0
sysfs                                    /sys              sysfs  defaults        0 0
proc                                      /proc              proc    defaults        0 0
proc                                      /proc              proc    defaults        0 0
/dev/vdb1                                /support-nfs-storage xfs defaults 0 0
/dev/vdb1                                /support-nfs-storage xfs   defaults       0 0
192.168.1.4:/volume1/wiki                /rackstation/wiki/ nfs4    defaults        0 0
192.168.1.4:/volume1/wiki                /rackstation/wiki/ nfs4    defaults        0 0
</pre>
</pre>

Latest revision as of 00:12, 3 July 2017

Internal

Overview

/dev/mapper/vg_oceanlab-lv_root           /                  ext4    defaults        1 1
UUID=5f7a5369-8936-4dd9-a128-37757851333f /boot              ext4    defaults        1 2
/dev/mapper/vg_oceanlab-lv_home           /home              ext4    defaults        1 2
/dev/mapper/vg_oceanlab-lv_swap           swap               swap    defaults        0 0
tmpfs                                     /dev/shm           tmpfs   defaults        0 0
devpts                                    /dev/pts           devpts  gid=5,mode=620  0 0
sysfs                                     /sys               sysfs   defaults        0 0
proc                                      /proc              proc    defaults        0 0
/dev/vdb1                                 /support-nfs-storage xfs   defaults        0 0
192.168.1.4:/volume1/wiki                 /rackstation/wiki/ nfs4    defaults        0 0

where:

first field

Describes the block special device or remote filesystem to be mounted.

second field

Describes the mount point for the filesystem. If the name of the mount point contains spaces these can be escaped.

third field

Describes the type of the filesystem. For the filesystems currently supported by the running kernel, see /proc/filesystems/.

fourth field

Describes the mount options associated with the filesystem.

fifth field

Is used for these filesystems by the dump command to determine which filesystems need to be dumped. If the fifth field is not present, a value of zero is returned and dump will assume that the filesystem does not need to be dumped.

sixth field

Is used by the fsck program to determine the order in which filesystem checks are done at reboot time. The root filesystem should be specified with a fs_passno of 1, and other filesystems should have a fs_passno of 2. Filesystems within a drive will be checked sequentially, but filesystems on different drives will be checked at the same time to utilize parallelism available in the hardware. If the sixth field is not present or zero, a value of zero is returned and fsck will assume that the filesystem does not need to be checked.

Mounting Network File Systems

Even if a network file system is specified in /etc/fstab, the filesystem is not mounted unless netfs service is started. For more details see netfs.

Mount a File System at Boot

Specify it in /etc/fstab:

...
/dev/sdc1               /generic-storage        ext4    defaults        0 0
...

Disable Swap at Runtime

Disable Swap at Runtime