[Samba] Setting uid and gid with smbmount

Joel Ebel jbebel at ncsu.edu
Wed Nov 3 22:04:17 GMT 2004


I'm having a problem setting the uid and gid properly using smbmount. 
I'm hoping someone can help with this issue.  I run:
mount -t smbfs -o username=technician,uid=500,gid=500 
//fileserver/technician /mnt/technician
and it mounts, but the uid and gid are all set to 1003 and 103 
respectively which is the uid and gid of the files on the server.  Am I 
making a mistake here?

Also, how can I make it follow the symlinks server-side, rather than 
deliver the symlinks to this client?

Some background for details if it's helpful.  I'm running slackware 10.0 
as a samba server with samba 3.0.5.  Most of the users run windows and 
Mac OS X, but I wanted to set up a demonstration workstation running 
open source software.  I set up a box with Red Hat Enterprise Linux 
Workstation 4.0 beta.  There appear to be a couple ways to connect to a 
samba share with it.  Nautilus has a built in samba client that works 
quite well, making the files all readable, and following symlinks just 
like I want.  The problem is that it isn't actually mounted in the 
filesystem, so programs such as the GIMP can't open remote files unless 
they are copied locally.  The alternative is to mount the smb filesystem 
as I'm trying to do.  I've added a line matching the mount command above 
to fstab, but I still run into two problems.  The most significant is 
that, as mentioned, the uid and gid are all incorrect, and I don't know 
how to correct it.  Secondly, and if anyone can help with this as well, 
symlinks don't work as I would like.  I would prefer for the symlinks to 
be followed on the server, rather than delivered as a symlink that 
points to an incorrect location on the client.  Or have other people 
solved this general Linux workstation using a shared server space in a 
different manner?

Thanks for the help,
Joel Ebel


More information about the samba mailing list