Mounting Windows Shares Automatically (at boot, at login)

George Gambill plug-discuss@lists.plug.phoenix.az.us
Thu, 19 Jun 2003 10:11:05 -0700


Austin,

Here is what worked for me for mounting Windows shares at boot time.
Haven't dealt with "login" time.

Note: ggambill is my windows host name and my windows login and my Linux
login.
      The Windows share is linuxshare

___ Make sure the Windows directory is shared and remember the password.

___ Create the credentials file (.smbpasswd) in your home directory (if
needed):
    ___ cd /home/ggambill
    ___ echo username=ggambill > .smbpasswd
    ___ echo password=YourWindowsPassWordHere >> .smbpasswd

___ Protect the credentials file from prying eyes
    ___ chmod 600 .smbpasswd

___ Create the Linux mount points using mkdir:
    ___ /mnt/linuxshare

___ In fstab (/etc/fstab on RH8) add the lines:

    ___ Format: //servername/sharename /mountdirectory smbfs
credentials=/home/myhomedirectory/.smbpasswd,uid=mylinuxusername 0 0
    ___ Examples:
        ___ //ggambill/LinuxShare /mnt/linuxshare smbfs
credentials=/home/ggambill/.smbpasswd,uid=ggambill
        Note: I didn't seem to need the ending " 0 0 "

___ Create Links (from the command line as root):
      (needed due to the error "smbmnt not running")
    ___ ln -s /usr/bin/smbmnt  /bin/smbmnt
    ___ ln -s /usr/bin/smbmount  /bin/smbmount

Note:  This check list evoolved as I was schucking and jiveing through the
process.  I have not wiped the slate clean and checked it from scratch.

Hote this Helps,

George


-----Original Message-----
--__--__--

Message: 11
Date: Wed, 18 Jun 2003 16:14:28 -0700
From: Austin Godber <godber@uberhip.com>
To: plug-discuss@lists.plug.phoenix.az.us
Subject: Re: Mounting Windows Shares Automatically (at boot, at login)
Reply-To: plug-discuss@lists.plug.phoenix.az.us

George!
	Did you have any luck with pam_mount?  I am trying to use it right
now 
with little luck.  Anyone out there use winbind and then somehow have 
the domain user's home directory automatically mounted off a server 
automatically after login ... and have it work?
	Perhaps LDAP with NFS is the best solution.
Austin