I have a computer named nexus with two hard drives, /dev/sdb0 and /dev/sdb1. My /etc/fstab is:
#
# /etc/fstab
# Created by anaconda on Sat Sep 30 15:29:58 2023
#
# Accessible filesystems, by reference, are maintained under '/dev/disk/'.
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.
#
# After editing this file, run 'systemctl daemon-reload' to update systemd
# units generated from this file.
#
/dev/mapper/rl-root / xfs defaults 0 0
UUID=2db34dbb-e0ee-41dd-9e8f-06aacb27ea08 /boot xfs defaults 0 0
/dev/mapper/rl-home /home xfs defaults 0 0
/dev/mapper/rl-swap none swap defaults 0 0
/dev/sdb1 /disk2 ext4 defaults 1 2
The last line mounts my second disk as /disk2, and usually this works fine. However, every third or fourth time I boot, it fails because the system has already mounted /dev/sdb1 as /boot. The relevant /var/log/messages entries from the last time this happened are:
Feb 2 13:39:03 nexus systemd[1]: Reached target Preparation for Local File Systems.
Feb 2 13:39:03 nexus systemd[1]: Mounting /boot...
Feb 2 13:39:03 nexus systemd[1]: Mounting /home...
Feb 2 13:39:03 nexus systemd[1]: Starting File System Check on /dev/sdb1...
Feb 2 13:39:03 nexus kernel: XFS (dm-2): Mounting V5 Filesystem 3bededc8-ba90-4f2d-9458-80d4ca32fa9b
Feb 2 13:39:03 nexus kernel: XFS (sdb1): Mounting V5 Filesystem 2db34dbb-e0ee-41dd-9e8f-06aacb27ea08
Feb 2 13:39:04 nexus kernel: XFS (dm-2): Ending clean mount
Feb 2 13:39:04 nexus systemd[1]: Mounted /home.
Feb 2 13:39:04 nexus kernel: XFS (sdb1): Ending clean mount
Feb 2 13:39:04 nexus systemd[1]: Mounted /boot.
Feb 2 13:39:04 nexus systemd-fsck[833]: /dev/sdb1 is mounted.
Feb 2 13:39:04 nexus systemd-fsck[833]: e2fsck: Cannot continue, aborting.
Feb 2 13:39:04 nexus systemd-fsck[815]: fsck failed with exit status 8.
Feb 2 13:39:04 nexus systemd-fsck[815]: Ignoring error.
Feb 2 13:39:04 nexus systemd[1]: Finished File System Check on /dev/sdb1.
Feb 2 13:39:04 nexus systemd[1]: Mounting /disk2...
Feb 2 13:39:04 nexus kernel: /dev/sdb1: Can't open blockdev
Feb 2 13:39:04 nexus mount[834]: mount: /disk2: /dev/sdb1 already mounted on /boot.
Feb 2 13:39:04 nexus systemd[1]: disk2.mount: Mount process exited, code=exited, status=32/n/a
Feb 2 13:39:04 nexus systemd[1]: disk2.mount: Failed with result 'exit-code'.
Feb 2 13:39:04 nexus systemd[1]: Failed to mount /disk2.
Feb 2 13:39:04 nexus systemd[1]: Dependency failed for Local File Systems.
Feb 2 13:39:04 nexus systemd[1]: Dependency failed for Mark the need to relabel after reboot.
Feb 2 13:39:04 nexus systemd[1]: selinux-autorelabel-mark.service: Job selinux-autorelabel-mark.service/start failed with result 'dependency'.
Feb 2 13:39:04 nexus systemd[1]: local-fs.target: Job local-fs.target/start failed with result 'dependency'.
Does anyone know why this happens, and what I can do to prevent from occurring in the future? I’m running Rocky Linux release 9.5 (Blue Onyx). Thanks to all who respond.