You are not logged in.
I am having trouble configuring my fstab to allow me to manually mount my external hard drive after booting. When I mount as superuser with
sudo mount -U 6e80b340-52a3-4a52-a7f1-11ac2feabd1a /home/damien/Games it works great. But when I use
sudo mount /home/damien/Games or
mount /home/damien/Games , it gives the following error:
mount: /home/damien/Games: wrong fs type, bad option, bad superblock on /dev/sdc1, missing codepage or helper program, or other error. This is my fstab (the last line is the line to do with my external drive). I have also tried setting ext4 to auto to no avail.
# Static information about the filesystems.
# See fstab(5) for details.
# <file system> <dir> <type> <options> <dump> <pass>
# /dev/sdb1 LABEL=root
UUID=2a72b552-9914-4bc4-90b7-7cae42309be7 / btrfs rw,nodev,relatime,ssd,discard,space_cache,subvolid=256,subvol=/__current/root,subvol=__current/root 0 0
UUID=2a72b552-9914-4bc4-90b7-7cae42309be7 /run/btrfs-root btrfs rw,nodev,relatime,ssd,discard,space_cache,nosuid,noexec 0 0
# /dev/sdb2
UUID=E445-38E7 /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro 0 2
# /dev/sda1 LABEL=home
UUID=bd613623-579e-4117-9a51-62a05ab8af0e /home btrfs rw,nodev,relatime,ssd,discard,space_cache,subvolid=257,subvol=/__current/home,subvol=__current/home 0 0
UUID=bd613623-579e-4117-9a51-62a05ab8af0e /run/btrfs-home btrfs rw,nodev,relatime,ssd,discard,space_cache,nosuid,noexec 0 0
# /dev/sdb3
UUID=f69f09b0-76d0-4d63-b838-6d6b078cf5ab none swap defaults 0 0
# /dev/sdc1
UUID=6e80b340-52a3-4a52-a7f1-11ac2feabd1a /home/damien/Games ext4 ro,user,noauto,unhide,x-systemd.automount,x-systemd.device-timeout=1ms,nofail 0 2Last edited by DAMO238 (2020-04-15 15:14:02)
Offline
It's set up to automount in your fstab, so you wouldn't need to manually use the mount command. Just `cd` to it, or use whatever you want in it and it would me mounted by systemd.
The error, however, suggest there is another problem. Please post the output of `lsblk -f`.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
I thought it would only automount on boot, or did I misunderstand the wiki? Here is my lsblk:
NAME FSTYPE FSVER LABEL UUID FSAVAIL FSUSE% MOUNTPOINT
sda
├─sda1 btrfs root 2a72b552-9914-4bc4-90b7-7cae42309be7 25.5G 77% /run/btrfs-root
├─sda2 vfat FAT32 E445-38E7 236.1M 19% /boot
└─sda3 swap 1 f69f09b0-76d0-4d63-b838-6d6b078cf5ab [SWAP]
sdb
└─sdb1 btrfs home bd613623-579e-4117-9a51-62a05ab8af0e 700.6G 25% /run/btrfs-home
sdc
└─sdc1 ext4 1.0 6e80b340-52a3-4a52-a7f1-11ac2feabd1a Offline
You set up systemd automount, that will take care of mounting on access, however I do think that a device timeout of 1ms is likely to be very sporty, up that to something reasonable, like 1mins or so. Or if you really want to manually mount, remove all the systemd related flags.
Maybe elaborate on your end goal, why do you explicitly want to mount manually or do you actually want an "on-access" automount?
Last edited by V1del (2020-04-15 14:58:51)
Offline
It doesn't mount on access though, even after increasing the timeout to 1 min (given that by specifying the UUID as root, it mounts just fine in a split second).
Offline
Well "as root" you are manually specifying the mount device and the mountpoint, so it will ignore your fstab.
Is the (unmounted) Games path owned by your user and not root? What's the output of "mount" when successfully mounting the partition? FWIW if I'm reading man mount correctly, the unhide option is bogus and invalid for ext4
And check your dmesg, invalid mount invocations often leave information there.
Last edited by V1del (2020-04-15 15:01:41)
Offline
Ah yes, the unhide was not allowed. There was no trace of the mounting failures in dmesg, but they were in journelctl (should have looked there before making this post tbh). It said that unhide was an invalid option there. So I got rid of that option and now it works manually, but it does not auto mount, but that is not really a problem. Thanks for all the help everyone!
Offline