Most fstab lines end in two numbers, and people copy them from somewhere without a second look. The fifth is for the old dump backup tool. The sixth, fs_passno, tells fsck whether and in which order to check the filesystem at boot, and it’s worth setting on purpose.
UUID=<root-uuid> / ext4 defaults 0 1
UUID=<data-uuid> /mnt/data ext4 defaults 0 2
192.168.1.x:/export /mnt/nas nfs defaults 0 0
The fstab man page gives the rule: 1 for the root filesystem, 2 for other filesystems you want checked, and 0 (also the default when the field is missing) for no check. A network share like the NFS line gets 0, because there’s nothing for the local machine to check.
On a systemd machine, though, the number is mostly a yes or no. systemd-fstab-generator treats passno as a boolean and throws the ordering away, except that root is still checked first. Other filesystems may then be checked in parallel, unless they’re on the same rotating disk. So a 3 doesn’t make a disk wait for the ones marked 2.
A 2 also doesn’t mean a full check at every boot. systemd-fsck runs the checker for that filesystem type, and that checker decides whether a check is needed, for example after an unclean shutdown or once a set number of mounts has passed.
One caveat for XFS. Its fsck.xfs simply exits with success, because XFS replays its journal at mount time, so a 2 on an XFS line does nothing. To really check an XFS filesystem you’d run xfs_repair on it while it’s unmounted. For ext4 data disks I’d use 2, for XFS and network shares 0.
Further reading: fstab(5) manual page, [email protected](8) manual page, fsck.xfs(8) manual page