[Gllug] Banging my head against samba

Simon Morris mozrat at gmail.com
Tue Jun 6 23:17:28 UTC 2006


On 06/06/06, Rich Walker <rw at shadow.org.uk> wrote:
[snip]
> My automounter has the "usual" debian /etc/auto.smb:
> #!/bin/bash
>
> # $Id: auto.smb,v 1.3 2005/04/05 13:02:09 raven Exp $
>
> # This file must be executable to work! chmod 755!
>
> key="$1"
> opts="-fstype=smbfs"
>
> for P in /bin /sbin /usr/bin /usr/sbin
> do
>         if [ -x $P/smbclient ]
>         then
>                 SMBCLIENT=$P/smbclient
>                 break
>         fi
> done
>
> [ -x $SMBCLIENT ] || exit 1
>
> $SMBCLIENT -gNL $key 2>/dev/null| awk -v key="$key" -v opts="$opts" -F'|' -- '
>         BEGIN   { ORS=""; first=1 }
>         /Disk/  { if (first) { print opts; first=0 }; sub(/ /, "\\ ", $2); print " \\\n\t /" $2, "://" key "/" $2 }
>         END     { if (!first) print "\n"; else exit 1 }

Hi Rich,

Afraid I can't give you a full answer here as this happened when I was
on Debian and I sinced moved to SUSE (where it didn't happen) but...

I recollect changing the "$SMBCLIENT -gNL $key " line and inserting
the argument to include a credentials file..

$SMBCLIENT -gNL $key -A /etc/smb.auth

smb.auth should be in the syntax

username="joe.bob"
password="somepassword"
domain="SOMEDOMAIN"

HTH

-- 
~sm
Jabber: mozrat at gmail.com
www: http://beerandspeech.org
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list