You are not logged in.
Pages: 1
automount is able to start and stop correctly but it does not mount my thumbdrive, how do I solve this?
/media does not contain any directories or files
/etc/autofs/auto.master
# Sample auto.master fi# Sample auto.master file
# Format of this file:
# mountpoint map options
# For details of the format look at autofs(5).
/media /etc/autofs/auto.misc
/etc/autofs/auto.misc
# This is an automounter map and it has the following format
# key [ -mount-options-separated-by-comma ] location
# Details may be found in the autofs(5) manpage
usbstick -fstype=auto,async,nodev,nosuid,umask=000 :/dev/sdb1
cdrom -fstype=iso9660,ro,nodev,nosuid :/dev/scd0
floppy -fstype=auto,async,nodev,nosuid,umask=000 :/dev/fl
/etc/conf.d/autofs
#localoptions='rsize=8192,wsize=8192'
# e.g. --timeout=60
daemonoptions='timeout=60,ghost'
/var/log/daemon.log
automount[5765]: syntax error in nsswitch config near [ syntax error ]
Last edited by unregistered (2009-06-23 14:33:46)
Offline
Could you have a look at /etc/nsswitch.conf or post it? I don't really know what nsswitch does but I have it on my system and I use autofs. You mentioned the automount service starts and stops ok. Can you actually see the automount process running in ps or htop?
Last edited by mikesd (2009-06-21 07:50:49)
Offline
# Begin /etc/nsswitch.conf
passwd: files
group: files
shadow: files
publickey: files
hosts: files dns
networks: files
protocols: db files
services: db files
ethers: db files
rpc: db files
netgroup: db files
# End /etc/nsswitch.conf
result of ps -aux | grep automount
root 4788 0.0 0.0 2124 776 ? Ssl 16:02 0:00 /usr/sbin/automount timeout=60,ghost
if it means anything, i deleted the directories that were originally in /media like dvd, cd, etc
i originally had auto.master point to those directories and it worked using another configuration but once I switched and deleted those directories, it didn't.
Last edited by unregistered (2009-06-21 08:13:56)
Offline
if it means anything, i deleted the directories that were originally in /media like dvd, cd, etc
i originally had auto.master point to those directories and it worked using another configuration but once I switched and deleted those directories, it didn't.
Hmm, that nsswitch error is weird. Not sure what is causing that. Maybe unrelated.
That is the configuration I am using. I have an empty /media directory. I don't have the ghost option specified anywhere I can find but get the functionality anyway, ie I see the directories in media when automount starts up whether the device is plugged in or not. Maybe try it without that option? I take it that /dev/sdb1 is appearing when the device is pluged in. What about permissions on /media? Clasping at straws now.
Offline
here are the permissions
drwxr-xr-x 2 root root 4096 2009-06-21 14:18 media
fdisk -l shows /dev/sdb1
no changes without the ghost option
Offline
bump i still need help
Offline
When I had a problem with autofs following an upgrade, I have debugged it by running /usr/sbin/automount from the command line.
If you look at /etc/rc.d/autofs, you can see the command that is run.
When you start the daemon the output is sent to /dev/null.
By running automount, you may see other usefull info.
Fyi, my problem was the -ghost option was unrecognized.
Cheers
Last edited by dobedo (2009-06-22 18:51:12)
Offline
i stopped autofs using /etc/rc.d/autofs stop and then started automount and the strange thing is automount worked, it automounted my usb stick but when I start it the daemon on bootup, it didn't. What gives and how do I solve it?
ok so i discovered this:
-when i start by running automount it worked
-when i start it using /etc/rc.d/autofs it says DONE but it doesn't work
output from /var/log/daemon.log
automount[5113]: syntax error in nsswitch config near [ syntax error ]
automount[5113]: lookup_nss_mount: key "umou" not found in map.
automount[5113]: lookup_nss_mount: key ".hal-mtab" not found in map.
Last edited by unregistered (2009-06-23 01:30:29)
Offline
ok so the error was in the /etc/conf.d/autofs file
when i changed this:
#localoptions='rsize=8192,wsize=8192'
# e.g. --timeout=60
daemonoptions='timeout=60'
to this:
#localoptions='rsize=8192,wsize=8192'
# e.g. --timeout=60
daemonoptions=''
everything seemed to work fine, what's wrong with the timeout option?
Offline
I would say: '--timeout=60' instead of 'timeout=60'
Offline
hmm i remember getting an error with '--timeout=60' but nvm I'll sort that out, anyway, all timeout does is unmount the device after the time specified in seconds as the argument right?
Offline
hmm i remember getting an error with '--timeout=60' but nvm I'll sort that out, anyway, all timeout does is unmount the device after the time specified in seconds as the argument right?
Yes. I don't have that option set. I think the default is something like 5 or 10 minutes. I often use 'sudo killall -USR1 automount' to unmount devices so I can remove them.
Offline
You can do that in your auto.master, i.e.:
/mnt/media /etc/autofs/auto.removable --timeout=2
/mnt/nfs /etc/autofs/auto.nfs --timeout=60
You need to install an RTFM interface.
Offline
ok problem solved, thanks for the help
Offline
Pages: 1