We have 2 ubuntu 8.04 LTS fileservers running samba version 3.0.28a-1ubuntu4.12, they export samba shares for windows server 2003 machines. There is no windows AD domain, just plain user authentication. From /etc/samba/smb.conf
:
[global]
workgroup = WORKGROUP
security = SHARE
passdb backend = smbpasswd:/etc/samba/smbpasswd
unix password sync = no
syslog = 0
log file = /var/log/samba/log.%m
max log size = 1000
dns proxy = No
panic action = /usr/share/samba/panic-action %d
encrypt passwords = true
invalid users = root
hosts allow = 10.1.1.0/24
[md0]
comment = md0
path = /mnt/md0/smb/share1
valid users = user1
force user = root
force group = root
read only = no
create mask = 0660
directory mask = 0770
browseable = Yes
/mnt/md0/
is a raid system and file permissions are root.root
for historical reasons.
On a windows server 2003 machine we access the share with a script:
net use t: \\fileserver0\md0 passwordforuser1 /user:user1
On the windows machine we now see Unix user\root
as the owner:
This is logically correct.
But is there a chance to change samba configuration so we see user1.user1
as owner on the windows side instead of Unix user\root
?
First, You could adjust the groupmappings in samba, to adjust the group that will be shown :
Second, You can map individual users by modifying samba.conf by adding
to the [global] section, and then making the file /etc/samba/smbusers containing :