Carlos Konstanski on 19 Aug 2005 00:31:48 -0000 |
There may be more to the story of samba access than file permissions. Samba has its own idea of users. You need to set this up. Start by adding this line to the [global] section of your smb.conf file: [global] ... encrypt passwords = Yes valid users = nobody,root,<your-users> ... This sets up the user permissions mechanism in samba. Now you need to define all these users in 2 files: smbusers and smbpasswd. Both live in the same directory as smb.conf (probably /etc/samba/). smbusers gets edited by hand. It is a list of users, one per line, with all aliases listed after the "=" sign. Example: nobody = nobody guest pcguest smbguest root = root carlos = carlos wde = wde lincoln = lincoln nick = nick This is a complete, legal smbusers file. smbpasswd is different. You use this command to write entries in this file: smbpasswd -a <username> An NT-style encrypted password gets written to smbpasswd for the user when this command is executed and a password is entered (twice) at the prompt. This makes it compatible with winblows. Then restart samba with: /etc/init.d/samba restart See if this changes anything for you. *************************** Just for the sake of completeness, here's a smb.conf file from a samba server on a big network that is known to work. It is the master browser, the domain master, everything. You can do without the "remote announce" and "remote browse sync" entry. [global] workgroup = WORKGROUP netbios name = HAL server string = Samba Server on HAL encrypt passwords = Yes map to guest = Bad User password level = 8 username level = 5 log level = 2 max log size = 0 socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192 os level = 99 preferred master = Yes domain master = Yes local master = Yes enhanced browsing = Yes remote announce = 192.168.1.255/WORKGROUP 192.168.1.208/WORKGROUP remote browse sync = 192.168.1.255 wins support = Yes dns proxy = No valid users = nobody,root,wde,carlos,lincoln,nick create mask = 0777 directory mask = 0777 hosts allow = 127.0.0.1 192.168.27.0/24 192.168.16.0/24 192.168.2.0/24 192.168.4.0/24 192.168.8.0/24 hosts deny = 0.0.0.0/0 [homes] comment = Home Directories valid users = %S read only = No create mask = 0755 force create mode = 0755 security mask = 0755 directory mask = 0755 directory security mask = 0755 inherit permissions = Yes [printers] comment = All Printers path = /var/spool/samba guest ok = Yes printable = Yes browseable = No [public] comment = Public share on HAL path = /var/samba read only = No force create mode = 0777 guest ok = Yes Carlos On Thu, 18 Aug 2005, Adam Zion wrote: Date: Thu, 18 Aug 2005 19:07:31 -0400 From: Adam Zion <azion@cceb.med.upenn.edu> Reply-To: Philadelphia Linux User's Group Discussion List <plug@lists.phillylinux.org> To: plug@lists.phillylinux.org Subject: [PLUG] Problems mounting linux samba share as read-write *from* a linux box ___________________________________________________________________________ Philadelphia Linux Users Group -- http://www.phillylinux.org Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug
|
|