1

First, I am using Samba because, though primary computers are Ubuntu 14.04, I have Windows laptops. These laptops should gain read access to the primary database. The primary database is on my "server" which is one of the Ubuntu machines.

I'm going from one problem to the next and can't seem to get it right. Help would be greatly appreciated.

Here are the requirements:

-The database that I want to share/edit is located at /home/valleysecurity/Documents/Shared/ on one of the Ubuntu machines, which I will call "server." There are folders and files in that folder.All other Ubuntu machines I will call "client."
- On all Ubuntu computers there are the same users, admin, valleysecurity, and technicalsupport. Each user has the same SID and password on each computer. - Only those users can edit/change/modify files and folders. - When a new document or folder is created, it should have the same security attributes as the rest of the folder hierarchy: user = {whoeverCreatedit}, group = valleygatehouse. - all three users are defined in a group "valleygatehouse".
- all the computers are in a workgroup called "valleygatehouse"

Current Problem:

From a client, I can see the valleygatehouse group, but, when I click on the group, I get challenged for a password. The challenge has already filled in the userid, which is whatever user I am at the moment. It will not accept the password and continues to ask for the password. How do I fix this?

Note: I am very confused about whether to use the built-in functions of Nautilus, the Samba user interface, or to edit the .conf file or whatever. It seems they work at cross purposes. Plus, the "current" documentation is all over the place in terms of naming conventions; eg, smbusers vs users to contain the users, and whether or not this file should contain all the users plus some other stuff or just one user???? Arghh!

PS. I can remove this problem by using Nautilus to change all folders to allow guests for Samba and to allow RW for "others." But that defeats a security requirement. In addition, when I create a new document on the client, its user is "nobody" and its group is "nobody."

And at that point, what does smb.conf have to do with anything?

Server smb.conf:


[global]

    workgroup = valleygatehouse
    server string = %h server (Samba, Ubuntu)
    server role = standalone server
    dns proxy = no
    name resolve order = lmhosts wins bcast host
    log file = /var/log/samba/log.%m
    max log size = 1000
    syslog = 0
    panic action = /usr/share/samba/panic-action %d
    encrypt passwords = no
;   passdb backend = tdbsam
;   obey pam restrictions = yes

# This boolean parameter controls whether Samba attempts to sync the Unix
# password with the SMB password when the encrypted SMB password in the
# passdb is changed.
;   unix password sync = yes

# For Unix password sync to work on a Debian GNU/Linux system, the following
# parameters must be set (thanks to Ian Kahan  for
# sending the correct chat script for the passwd program in Debian Sarge).
    passwd program = /usr/bin/passwd %u
    passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .

    guest account = nobody
;   username map = /etc/samba/smbusers


[Shared]
    comment = Valley Security documents
    path = /home/valleysecurity/Documents/Shared
    browseable = yes
    guest ok = yes
    available = yes
    writeable = yes
    read only = no
    username = valleysecurity,admin,technicalsupport
    create mask = 0775
    directory mask = 0775
[printers]
    comment = All Printers
    browseable = yes
    path = /var/spool/samba
    printable = yes
    guest ok = yes
    read only = no
    create mask = 0700
[print$]
    comment = Printer Drivers
    path = /var/lib/samba/printers
    browseable = yes
    writeable = yes
    read only = no

Client smb.conf


[global]
   workgroup = valleygatehouse
   server string = Samba Server
   server role = standalone server
   log file = /usr/local/samba/var/log.%m
   max log size = 50
   dns proxy = no 
[homes]
   comment = Home Directories
   browseable = no
   writable = yes
[printers]
    comment = All Printers
    browseable = yes
    path = /var/spool/samba
    printable = yes
    guest ok = yes
    read only = no
    create mask = 0700
[print$]
    comment = Printer Drivers
    path = /var/lib/samba/printers
    browseable = yes
    writeable = yes
    read only = no

1

Try using

valid users = valleysecurity,admin,technicalsupport

instead of

username = valleysecurity,admin,technicalsupport

and be sure that users/passwords have been created on the "server".

I have machines running configured similar to your "Server side" smb.conf except by users field. Hope that helps.

0

Each time I setup a samba server in linux with the permission of write, I will run the command "smbpasswd 'username'"to add the user to a samba user, note that the user should be in the system frist.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.