You are not logged in.
Hello everyone.
I am having trouble "automagically" mounting removable media.
I followed the instructions on the autofs wiki page. Edited /etc/autofs/auto.master misc line to:
/media/misc /etc/autofs/auto.misc
Then added the line to /etc/autofs/auto.misc:
usbstick -fstype=auto,async,nodev,nosuid,umask=000 :/dev/sdb1
Edited /etc/defaults/autofs to get logging:
OPTIONS="--verbose"
While on this file I ensure that use misc option was enabled:
USE_MISC_DEVICE="yes"
Tested a usb media manually, and watched with jornalctl -kf:
kernel: usb 2-1: new high-speed USB device number 78 using xhci_hcd
kernel: usb-storage 2-1:1.0: USB Mass Storage device detected
kernel: scsi host24: usb-storage 2-1:1.0
kernel: scsi 24:0:0:0: Direct-Access USB Flash Memory PMAP PQ: 0 ANSI: 4
kernel: sd 24:0:0:0: [sdb] 30489408 512-byte logical blocks: (15.6 GB/14.5 GiB)
kernel: sd 24:0:0:0: [sdb] Write Protect is off
kernel: sd 24:0:0:0: [sdb] Mode Sense: 23 00 00 00
kernel: sd 24:0:0:0: [sdb] No Caching mode page found
kernel: sd 24:0:0:0: [sdb] Assuming drive cache: write through
kernel: sdb: sdb1
kernel: sd 24:0:0:0: [sdb] Attached SCSI removable disk
The kernel detects the device, and I am able to mount the device manually.
Then I started autofs and watched the logs, with journalctl -fu autofs:
systemd[1]: Starting Automounts filesystems on demand...
automount[29512]: Starting automounter version 5.1.1, master map auto.master
automount[29512]: using kernel protocol version 5.02
automount[29512]: lookup(file): failed to read included master map auto.master
automount[29512]: mounted indirect on /media/misc with timeout 300, freq 75 seconds
automount[29512]: mounted indirect on /net with timeout 300, freq 75 seconds
systemd[1]: Started Automounts filesystems on demand.
The /media/misc directory gets created, but nothing appears there when I plug in the usb device.
This message did caught my attention:
automount[29512]: lookup(file): failed to read included master map auto.master
Although Google wasn't very helpful, I could only find a tipc on this 2012 forum thread which at the end, it says to commend the following line on /etc/autofs/auto.master:
+auto.master
I did tried that, and the lookup(file) error does indeed go away, but still cannot automount removable media.
I did also check file permissions and everything is 0644.
Any suggestions would be welcome.
Last edited by masterkorp (2015-09-09 22:19:42)
Regards,
Alfredo Palhares
Offline