Package: autofs
Version: 4.1.4+debian-1
Severity: normal
I am trying to use autofs to automount a Samba filesystem exported by
a machine whose IP address is assigned dynamically. To find the IP
address I need to do a lookup in the .local namespace using Avahi.
(It turns out with the very latest autofs this isn't necessary, but
with earlier versions it seemed to be.)
So I created the following executable map file:
#!/bin/ksh
set -x
key="$1"
server=$(getent hosts $key.local)
server="${server%% *}"
echo "$key -fstype=cifs,rw,guest,uid=32074,gid=6202 ://$server/SharedDocs"
Unfortunately, this output is not understood, as you can see by the log:
Jan 12 20:49:41 localhost automount[1571]: >> + key=bloodhound
Jan 12 20:49:41 localhost automount[1571]: >> + getent hosts bloodhound.local
Jan 12 20:49:41 localhost automount[1571]: >> + server='192.168.2.33
bloodhound.local'
Jan 12 20:49:41 localhost automount[1571]: >> + server=192.168.2.33
Jan 12 20:49:41 localhost automount[1571]: >> + echo 'bloodhound
-fstype=cifs,rw,guest,uid=32074,gid=6202 ://192.168.2.33/SharedDocs'
Jan 12 20:49:46 localhost automount[1571]: mount(nfs): host -fstype=cifs:
lookup failure
Jan 12 20:49:55 localhost automount[1571]: mount(nfs): host uid=32074: lookup
failure
Jan 12 20:49:55 localhost automount[1571]: mount(nfs): host gid=6202: lookup
failure
Jan 12 20:49:55 localhost automount[1571]: mount(nfs): host : lookup failure
Jan 12 20:50:09 localhost automount[1571]: >> mount to NFS server
'bloodhound' failed: server is down.
Jan 12 20:50:09 localhost automount[1571]: mount(nfs): nfs: mount failure
bloodhound://192.168.2.33/SharedDocs on /var/autofs/smb/bloodhound
Jan 12 20:50:09 localhost automount[1571]: failed to mount
/var/autofs/smb/bloodhound
My auto.master file is as follows:
#
# $Id: auto.master,v 1.4 2005/01/04 14:36:54 raven Exp $
#
# Sample auto.master file
# This is an automounter map and it has the following format
# key [ -mount-options-separated-by-comma ] location
# For details of the format look at autofs(5).
/misc /etc/auto.misc --timeout=60
/var/autofs/smb /etc/auto.mysmb --timeout=60
/var/autofs/testsmb /etc/auto.testsmb --timeout=60
#/misc /etc/auto.misc
#/net /etc/auto.net
/var/autofs/bigusb /etc/auto.bigusb --timeout=500
And when I use the same text in a non-program map, it works:
% cat /etc/auto.testsmb
bloodhound -fstype=cifs,rw,guest,uid=32074,gid=6202 ://192.168.2.33/SharedDocs
% ls /var/autofs/smb/bloodhound/
ls: /var/autofs/smb/bloodhound/: No such file or directory
# ls /var/autofs/testsmb/bloodhound/
2004IFresults.html EA Games My Music My Videos
2004IFresults_files My Games My Pictures desktop.ini
I assume that something goes wrong with the parsing of output from
program maps, but I don't know how to trigger more debugging
information from the daemon.
Norman
-- System Information:
Debian Release: 4.0
APT prefers testing
APT policy: (500, 'testing'), (500, 'stable'), (50, 'unstable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.17-2-k7
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Versions of packages autofs depends on:
ii libc6 2.3.6.ds1-8 GNU C Library: Shared libraries
ii ucf 2.0017 Update Configuration File: preserv
Versions of packages autofs recommends:
ii nfs-common 1:1.0.10-4 NFS support files common to client
-- no debconf information
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]