Thursday, February 09, 2006
Samba/smbfs in fstab
I had success with this.
Put this line in /etc/fstab
The file /etc/file-server-credentials.conf contains the log on information
Then lock down the permissions on /etc/file-server-credentials.conf to restrict read access.
Edit /etc/groups and add the approriate users to fileserverusers group.
Put this line in /etc/fstab
//file-sever/thing /mymountpoint smbfs credentials=/etc/file-server-credentials.conf,gid=fileserverusers,fmask=660 0 0
The file /etc/file-server-credentials.conf contains the log on information
username=someusername
password=apassword
Then lock down the permissions on /etc/file-server-credentials.conf to restrict read access.
gid=fileserverusers
is to allow a group of users on the local linux box read write access to the /mymountpoint. This access is controlled my the fmask=660
groupadd fileserverusers
Edit /etc/groups and add the approriate users to fileserverusers group.