This has been asked before but the answers haven't worked for me.I upgraded from 2.2.7 to 3.0.0. I used to connect to Windows sharesusing smbmnt in .bash_profile as a non-root user having chmod 4755smbmnt. Now this doesn't work: - smbmount won't let non-root users run it (even after a chmod) - smbmnt says "Failed to find real path for mount point" - mount -t smbfs says "only root can do that".1. For Samba 3.0.0 what is the correct way for non-root users to mountWindows shares? (Which command? Is any chmod needed? Etc.).2. What are the correct permissions for smbmount, smbmnt, smbumount (Ididn't note these before I changed them as this fix worked fine with theprevious version).Many thanks for any help - I'm going to have to use Windows until I canfix this!(RedHat 9.0 BTW).Leon... ----------------------------------------- Email provided by http://www.ntlhome.com/
Leon Stringer wrote:>This has been asked before but the answers haven't worked for me.I upgraded from 2.2.7 to 3.0.0. I used to connect to Windows sharesusing smbmnt in .bash_profile as a non-root user having chmod 4755smbmnt. Now this doesn't work: - smbmount won't let non-root users run it (even after a chmod) - smbmnt says "Failed to find real path for mount point" - mount -t smbfs says "only root can do that".1. For Samba 3.0.0 what is the correct way for non-root users to mountWindows shares? (Which command? Is any chmod > >What about sudo? chmod 4755 is not really a secure way to allow users access to commands which have to be run as root, unless you are the only person working on this machine, and you are sure that no other person might actually login on your machine. sudo basically is a remedy for this. It allows a non-root user to execute commands as root if special premises are met (you can configure sudo to only allow certain commands to be run as a specific user, in this case you would configure sudo to allow smbmount with any number of parameters for your login). I personally use sudo for all the admin tasks I need to make available to users on my boxes (well, all my boxes have several users which can login, so security is a concern for me). If RedHat doesn't come with sudo preinstalled, install it using the rpm frontend RedHat provides (don't know too well about RedHat). Then do a man sudo to have a look at the config file syntax. HTH! Heiko.
That works for me! I had a bit of trouble working out the sudoers syntax. For the record the entry in /etc/sudoers: leons ALL=(ALL) NOPASSWD:/usr/sbin/smbmount //10.0.0.1/Users /home/leons/home -o credentials\=.credentials\,workgroup\=STAFFAMB\,uid=leons The command: sudo /usr/sbin/smbmount //10.0.0.1/Users ~/home -o credentials=.credentials,workgroup=STAFFAMB,uid=leons Thanks for your help, Leon...> > From: Heiko Wundram <heikowu@ceosg.de> > Date: 2003/10/22 Wed AM 07:14:55 GMT > To: Leon Stringer <leon.stringer@ntlworld.com> > CC: samba@lists.samba.org > Subject: Re: [Samba] Mounting for non-root users > > What about sudo? chmod 4755 is not really a secure way to allow users > access to commands which have to be run as root, unless you are the only > person working on this machine, and you are sure that no other person > might actually login on your machine.----------------------------------------- Email provided by http://www.ntlhome.com/