Questions tagged [automounting]
Automounting is the process where mounting and unmounting of certain filesystems is done automatically by a daemon.
430
questions
0
votes
0
answers
15
views
How to automatically mount ZFS external USB flash drive when I insert it
In Ubuntu 20.04, I installed the zfsutils-linux package and formatted an external USB thumbdrive to use ZFS (sudo zpool create mypool /dev/sdb). I then changed its mount point to /media/user/mypool (...
0
votes
0
answers
11
views
How to unplug/unmount USB Flash card, which was automounted?
I have configured my flash card to automount with the following lines inf fstab:
UUID=6364-3963 /mnt/Flash03 auto noauto,nofail,x-systemd.automount,x-systemd.device-timeout=2
UUID=3537-3561 /mnt/...
0
votes
1
answer
72
views
How to auto-mount external drive without using /etc/fstab
I have mounted an external drive using an entry/etc/fstab , UUID=ba6274de-e241-43ef-9dd0-5147c29e883a /mnt/500GB_Seagate_Drive xfs defaults,x-gvfs-show 0 0
I have other drives with do not have an ...
0
votes
0
answers
23
views
Automount USB flash drive on CLI (no fstab solutions please!)
I have been looking for how to automount a USB flash/thumb drive on a Linux machine which does not have a GUI. So, it must be CLI-only solution. The most common answer I found was based on editing ...
0
votes
1
answer
30
views
Can I auto-mount all users in /home (using `*` key) except one?
Starting on a server where /home had just one user, I thought "adding" the home directories of the other users via NFS using automount's * and &.
Also the NFS has a home directory (but ...
0
votes
0
answers
62
views
Error in Starting Linux Operating System Due to Unmounted /home Partition
I have a problem with my Linux OS (Ubuntu), I was working normally, and suddenly I couldn't do anything, the files on my home were disabled, after the restart, the OS booted up, but not the graphical ...
0
votes
1
answer
58
views
Using /etc/auto.master.d together with wildcard `*` to mount `/home`
My problem is similar to that described in Need example use of autofs.master.d/:
I wanted to mount individual users' home directories to /home/*user* using both, * wildcard and directory /etc/auto....
0
votes
0
answers
17
views
Modify Fedora behavior when plugging in Canon DSLR via USB
I'm using gphoto2 to turn my old DSLR into a webcam over USB.
As soon as the USB is plugged, my Fedora mounts its SD Card as a drive. Here's what I need to do each time manually:
Unmount SD Card (I ...
0
votes
0
answers
28
views
Automount as another user (not logged)
When I plug a USB Key on my desktop install of a redhat fork, USB is automounted as /run/media//. I would like that plugged removable device will be automounted for another logged user (not the ...
0
votes
0
answers
26
views
How to add or modify systemd mount targets/conditions in unit file
I've got a .mount file that I globbed together as /etc/systemd/system/opt-hass-config.mount
[Unit]
Description=Mount the config dir of hass.mydomain.com
[Mount]
What=//[IP ADDRESS]/config
Where=/opt/...
0
votes
1
answer
33
views
Drives under /media/user/ are denoted by an alphanumeric string - how are they generated?
I noticed that my thumb drives and hard drivers are in the location /media/user and are denoted as a string of alphabets and numbers instead of their names such as 1A2B-3C4D. I never named my drives ...
2
votes
0
answers
139
views
BTRFS: error (device dm-0) in btrfs_run_delayed_refs:2150: errno=-5 10 failure
I have run this error while trying to boot my fedora linux 36 from my external SSD. I did boot it at home yesterday quite well, shut it down this morning. When I got to work today and tried booting it ...
1
vote
2
answers
547
views
How do I manually trigger systemd's "auto mounting" of encrypted partitions/drives?
I set up two LUKS encrypted drives to automount on system startup (using crypttab and a LUKS file key). It works fine, but unfortunately, if I disconnect one of the drives, the "auto decrypting&...
0
votes
1
answer
33
views
Unable to replicate fuse sshfs setup, with regular sshfs command
Goal: mount remote folder via sshfs on local system on boot
I have an empty USB attached to my machine: /media/steve/downloads-remote/
There is one folder inside the drive Downloads
The permissions of ...
0
votes
0
answers
158
views
what is the right way of mounting an ext4 formatted ssd or nvm?
I have mounted 2 external disks like this shown below (in fstab)
UUID=e3831bf2-d85d-459f-8091-4af1d3c6ee41 /mnt/ssd ext4 defaults 0 1
UUID=38cebf19-8cea-40ce-9014-d6f2f9d884ac ...
2
votes
1
answer
419
views
Unmount/mount drive when it's disconnected/connected, automatically
Is there a way for a systemd.mount unit to detect the state of a drive without having to reboot the computer, or reload the unit? If not, is there any other way to achieve this?
I would like to ...
2
votes
0
answers
53
views
systemd automount unit: run only when server is reachable
I am using systemd automount units (see below) to mount network shares on my laptop
(debian bullseye). This works fine in principle but I have one big issue:
At home it is enough to set TimeoutSec to ...
0
votes
1
answer
84
views
How do i safely remove a secondary mounted root in the fstab file
On my computer i have 2 drives, a 128GB SSD and a 1.8TB HDD. I mount the HDD on "/home/___/mountpoints/HDD" but today i found that leads me back to "/"
The "fstab" file ...
0
votes
1
answer
66
views
gdm's systemd user process triggers automount
I'm trying to set up a hard drive that's in an external enclosure, so I added the following fstab entry:
LABEL=Mothership /var/local/Mothership btrfs noauto,nofail,x-systemd.automount,x-systemd.idle-...
0
votes
0
answers
28
views
Mount unexpectedly calling espanso
The following happens as soon as I combine -a and -o remount - one flag individually does nothing, the adding of -f only removes expected permission warnings. Running as root produces the same output. ...
2
votes
2
answers
377
views
Give executable permissions to binary files on a USB
I have a desktop application that provides the user with a tarball (.tar.gz) that they can unpack to find the binary that can be run with executable permissions which starts the overall program. This ...
1
vote
0
answers
181
views
Mounting drive as unpriviliged user with systemd mount unit or systemd-mount
Is there any way to mount an external drive as an unpriviliged user, either with a pre-defined mount unit or with a transiently generated one with systemd-mount?
If I write a file run-media-myuser-...
0
votes
1
answer
123
views
automount disks but with dev name, not some random numbers
On Linux, all connected disks have ambiguous mountpoint names to user.
For example, if I connect a USB then Linux (udev?) mounts it to a directory like this:
/media/username/78128SDGHJ23G
But I want ...
0
votes
0
answers
174
views
Direct mapping works in autofs but indirect mapping does not
I have an NFS server where the /etc/exports file contains:
/shared *(rw,no_root_squash)
I want to use autofs in another machine (Rocky Linux 8) to mount that folder but only the direct mapping method ...
1
vote
0
answers
16
views
How can I automount my drive immediately on connection rather than on first access? [duplicate]
I have an external drive set up in my /etc/fstab with noatime,nofail,x-systemd.device-timeout=500ms,x-systemd.automount,users.
I also have several dependencies set up which only start when this drive ...
1
vote
1
answer
88
views
How to determine if mysql is using directory under mounted directory?
I currently have MySQL using /home/foo/data/database as its datadir. With /home/foo/data/database being a mounted raid 1 array. The problem I am having is that every once in awhile on boot MySQL is ...
0
votes
0
answers
691
views
File manager not authorized to mount external drives
I have a problem authorizing my file manager to mount external drives. Inside thunar, I get this error:
failed to mount "flash-drive"; not authorized to perform operation
I've already tried ...
0
votes
0
answers
48
views
SDCard reader not functioning at boot Lubuntu 21.10
I have installed lubuntu-21.10 on a Asus C423NA-BCLN5 device.
It comes with kernel 5.13.0-39-generic.
Now, I am having an issue with it's, otherwise perfect, card reader.
I have an SD card inside, ...
1
vote
0
answers
110
views
Systemd Automount Failing on Program Execution
I set up a systemd automount for an external drive by UUID. I basically just wanted the drive to mount whenever it's accessed. It was working fine but I noticed some issues when loading Evince first, ...
12
votes
1
answer
801
views
Drive mounted with flags different from /etc/fstab - not respecting suid, dev, or exec
I have an ext4 mounted with the flags rw,suid,dev,exec,auto,user,async in /etc/fstab but running mount after mounting gives rw,nosuid,nodev,noexec,relatime,user.
How do I get it to mount exactly as ...
0
votes
2
answers
32
views
Auto-mounting the 2nd internal HD
I'm editing the fstab file to automount my secondary HD and I would like to know how to setup the 'noatime' in the command line.
The command I have so far is:
UUID=DEVICEID /PATH ntfs-3g rw,...
2
votes
1
answer
2k
views
What happens when mounting network drives in fstab fails
I am responsible for maintaining a Linux (Ubuntu) machine in my company. We mounted some NFS network drives. In irregular intervals (during holidays), the machine is forcefully restarted because the ...
0
votes
2
answers
255
views
Unable to mount internal hdd - An error occurred while accessing 'Basic data partition'
I have 2 disks in my PC, an SSD with my linux system on it and a HDD with windows and some other stuff. Now I keep getting the following error, which appeared overnight without changing the system, ...
0
votes
0
answers
701
views
mount command on Alpine Linux doesn't like octal sequence for space in fstab
on alpine Linux, I can't mount automatically a cifs directory which has a space in the name, but manually it may work.
With this /etc/fstab snippet it doesn't work:
//192.168.245.1/My\040Space ...
0
votes
2
answers
56
views
How can different devices represented by the same device file be automatically mounted to different mounting points?
In Ubuntu, even if different block devices (e.g. an external hard drive and a flash drive) are represented by the same device file (e.g. /dev/sdb1) one after another, they are automatically mounted ...
0
votes
0
answers
120
views
What could have caused automount to try to mount this nonexistent directory?
In /var/log/messages I found entries like this
Oct 18 2:10:15 linux automount[946]: attempting to mount entry /home/randomusername
Oct 18 2:10:15 linux automount[946]: key "randomusername" ...
1
vote
1
answer
182
views
In search for good practices: Mounting disks
I think I did many terrible things at the past, empty directories everywhere, whatever priviledges they had and even mounting a fs inside other mounted fs.
Now I want to make the things right and ask ...
1
vote
1
answer
601
views
Why is /etc/fstab preferred over systemd unit files?
The systemd.mount(5) man page says (emphasis mine):
Mount units may either be configured via unit files, or via /etc/fstab (see fstab(5) for details). Mounts listed in /etc/fstab will be converted ...
1
vote
0
answers
78
views
Howto prevent Dolphin from triggering /foo/nfs-share.automount
since i switched to auto-suspend there's an unwanted delay when reactivating due to the lost nfs-mounts (debian 11)
I created some auto(u)mount (systemd) which is working fine... as long as dolphin is ...
0
votes
1
answer
380
views
How to allow "guix-daemon" to "remount" in SELinux?
I've installed Guix and installed the bundled SELinux policy manually. But according to Ricardo Wurmus, as of 30 June 2021:
There are really just two ways: either 1) disable SELinux (or set it to ...
2
votes
0
answers
93
views
How to figure out what is auto-mounting external drives
A long long time ago I apparently installed something that automounts removable drives to the /media directory. Now I can't figure out how to unmount stuff anymore. sudo umount on the correct /dev ...
1
vote
0
answers
408
views
Systemd service that only runs when USB Drive is mounted
I've been searching for an elegant way of automating a very tedious process.
This is the workflow I want to achieve:
Plug in the USB Disk (single partition)
sdX1 gets automatically mounted to /mnt/...
0
votes
0
answers
249
views
How to bind mount a directory in .bashrc without sudo privilege
NOTE: I'm working in WSL2, but my issues lies entirely within the Linux side of things. Please let me know if this is not the right place for this.
I am needing to mount --bind a directory whenever ....
2
votes
1
answer
586
views
automount removable media using udev in NixOS
I want an udevrule to automatically mount usb sticks or sd-cards, if plugged into a terminal-computer. The way I tried to achieve this was adding an udevrule and make use of pmount's ability to mount ...
1
vote
1
answer
5k
views
Consistent auto-mount of external hard-drive
Adding /dev/sdb1 /home/[user]/external_drive ntfs defaults,noatime 0 2 to /etc/fstab auto-mounts external drive after machine start/reboot.
However, if additional usb drive was plugged in during the ...
1
vote
1
answer
370
views
Systemd automount with custom command
I use tomb to store some files. I want to use a systemd .automount unit so that whenever I try to access these files, the tomb is automatically mounted. However, tombs are not mounted with mount, they ...
1
vote
1
answer
2k
views
How to solve failure in plugging external DVD driver in Ubuntu 20.04?
I have bought an external DVD driver but, after plugging (or booting with the unit already plugged) I see the unit listed in the resources of the computer but I cannot access it:
If I try to access ...
1
vote
0
answers
263
views
FreeBSD: Automount to specific location
First of all, I read Vermaden's blog which explained a couple different systems used for automounting. I like to use included utilities so I opted for autofs. Based on the information in the blog I ...
4
votes
1
answer
268
views
Prevent systemd from unmounting a partition mounted by a systemd service
I have a custom systemd service that automatically mounts some partitions under certains conditions. The service executes a shell script containing some mount commands. When I execute it directly, ...
0
votes
1
answer
985
views
Which is the correct mechanism for auto-mounting a USB flash drive at boot?
I'm seeing apparently conflicting information on the proper way to auto-mount USB flash drives at boot. Most instructions on how to do it say to use an entry in fstab. Gnome Disks has a built-in ...