12

For the life of me I cannot figure this one out.

I have samba installed and set up on the ubuntu box and on the Win7 box I CAN SEE all the shares I created.

I created two users on ubuntu that map to the users in windows. On ubuntu they are both admins, user A & B on Windows User A is admin and user B is poweruser.

User A can see both shares and access them, but user B can see everythin, but only access the homes directory, the other directory throws an error.

I have two drives in Ubuntu and this is the smb.config file (I am new to samba):

[global]
workgroup = WORKGROUP
server string = %h server (Samba, Ubuntu)
wins support = no
dns proxy = yes
name resolve order = lmhosts host wins bcast
log file = /var/log/samba/log.%m
max log size = 1000

syslog = 0

panic action = /usr/share/samba/panic-action %d
security = user

encrypt passwords = true
passdb backend = tdbsam

obey pam restrictions = yes

unix password sync = yes
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .

pam password change = yes
map to guest = bad user
;   usershare max shares = 100
usershare allow guests = yes

And here is the share section:

Both user A & B can access this from windows. No problems.

[homes]
comment = Home Directories
browseable = no
writable = yes

Both User A & B can see this share, but only user A can access it. User B get an error thrown.

[stuff]
comment = Unixmen File Server
path = /media/data/appinstall/
browseable = yes
;writable = no
read only = yes
hosts allow =

The permission for the media/data/appinstall/ is as follows:

appInstall properties:

share name: stuff
Allow others to create and delete files in this folder is cheeked
Guest access (for people without a user account) is checked

permissions:

Owner: user A
Folder Access: Create and delete files
File Access: ---

Group: user A
Folder Access: Create and delete files
File Access: ---

Others   
Folder Access: Create and delete files
File Access: ---

I am at a loss and need to get this work. Any ideas?

The goal is to have a setup like this. 3 users on window machines. Each user on the data drive will have their own personal folder where they are the ones that can only access, then another folder where 2 of the users will have read only and one user full access.

I had this setup before on windows, but after what happened I am NEVER going back to windows, so Unix here I am to stay!

I am really stuck. I am running Ubuntu 11. I could reformat again and put on version 10 if that would make life easier. I have been dealing with this since Wed. 3pm.

Thanks.

3
  • Tried by IP? \\192.168.0.10\share? If that works, the problem is narrowed to WINS.
    – user8290
    Nov 27, 2011 at 0:31
  • 1
    Same issue. I think it is a permission things on the unix side.
    – nitefrog
    Nov 27, 2011 at 5:25
  • whats the exact error message you're getting? What are the logfiles saying (/var/log/samba/*)? Nov 21, 2012 at 1:02

2 Answers 2

4

Name Resolution with Samba

I had the same problem with windows 7 To fix it All i had to do was change smb.conf

In terminal run

sudo gedit /etc/samba/smb.conf

Then change

wins support = no

name resolve order = lmhosts host wins bcast

To

wins support = yes

name resolve order = wins lmhosts host bcast

Then restart samba

sudo service smbd restart
2
  • mine doesn't have name resolve order = lmhosts host wins bcast. is this outdated?
    – endolith
    Dec 11, 2016 at 2:42
  • It is from March 11 2012. It probably is outdated
    – mlandiland
    Dec 14, 2016 at 21:54
1

that could happen if shared folder resides on FAT32 volume (e.g. flash card) and Ubuntu can't add permissions for samba to check. I'm not sure what is the right way to define access rights in that case but simple workaround is to move folder to ext4 volume and share it from there.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .