Skill 2 in course 2.3: Storage
File Systems, NFS and Autofs
Create and mount XFS, ext4 and VFAT, use NFS and autofs, and fix permission problems.
You will be able to
- Create XFS, ext4 and VFAT file systems with labels, and mount them by UUID or label persistently.
- Mount an NFS export manually and from /etc/fstab, and explain what fails when the server is unreachable.
- Configure autofs direct and indirect maps so shares mount on first access and unmount when idle.
- Diagnose a permission problem step by step and repair it with ownership, modes, setgid directories or ACLs.
Lessons
- 01XFS, ext4 and VFAT: create, label and mount permanentlyChoose a file system, format it, give it a label, and mount it at boot by UUID or label, then check the result before rebooting.
mkfs.xfsmkfs.ext4mkfs.vfatblkidxfs_admine2label0/5 exercises - 02Using NFS shares: mount manually and permanentlySee what a server exports, mount it by hand, make the mount permanent, and set up a throwaway server on one machine to practise.
mount -t nfsshowmountnfs-utilsexportfs/etc/exportsnfsstat -m0/5 exercises - 03Mounting on demand with autofsMount NFS shares only when someone uses them, with indirect, direct and wildcard maps, and unmount them again when idle.
autofs/etc/auto.master/etc/auto.master.dsystemctl reload autofsautomount -mfindmnt0/5 exercises - 04Diagnosing and fixing permission problemsWork out why access is denied, step by step, and fix it with ownership, modes, setgid directories and ACLs.
nameiidls -ldchownchgrpchmod0/5 exercises