I want to allow a user script to remount
a drive as "ro" or "rw".
By using the user
option in the fstab, I can successfully mount and unmount the drive as a user but the -o remount,rw
fails.
Is it not possible for the user to use the remount
option?!?
/etc/fstab
reads...
UUID=789f-4b3a-b0b2-c05955d7c5ad /mnt/nasbackup auto rw,user,noexec 0 2
but...
john@johnbox /mnt> mount UUID=789f-4b3a-b0b2-c05955d7c5adjohn@johnbox /mnt> mount | grep nvme/dev/nvme0n1 on /mnt/nasbackup type ext4 (rw,nosuid,nodev,noexec,relatime,stripe=4,user=john)john@johnbox /mnt> mount -o remount,ro UUID=789f-4b3a-b0b2-c05955d7c5admount: /mnt/nasbackup: must be superuser to use mount. dmesg(1) may have more information after failed mount system call.john@johnbox /mnt [32]> umount UUID=789f-4b3a-b0b2-c05955d7c5adjohn@johnbox /mnt>