I have two samba shares. One a public (local network) that anyone can see and change, this works great. I have another share that I want the username and password to be entered
[media]
comment = public share
path = /mnt/media_files
public = yes
read only = no
writeable = yes
create mask = 0777
directory mask = 0777
force user = nobody
force group = nogroup
guest ok = yes
[webroot]
comment = Apache web root folder
path = /var/www
public = yes
read only = no
writable = yes
create mask = 0777
directory mask = 0777
guest ok = no
I did have "force user = jon" as well but didn't seem to help.
The issue I have at the moment is that when I go to the share "\myip\webroot" I get the popup asking for the password, but the username is grayed out with "ip\Guest". How can I get it to either allow me to enter the username, or force it to just use "jon".
loging in from Windows7 machine seems to work better after fixing an issue with the smpasswd part. I set the password the same as my username accuont on W7 machine and all was good. Has a bit of an issue from other machines have to login with ip\jon otherwise it sets the domain to be the name of that computer.
TestParm output:
[global]
server string = %h server (Samba, Ubuntu)
security = SHARE
map to guest = Bad User
obey pam restrictions = Yes
passdb backend = tdbsam
pam password change = Yes
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
unix password sync = Yes
syslog = 0
log file = /var/log/samba/log.%m
max log size = 1000
dns proxy = No
usershare allow guests = Yes
panic action = /usr/share/samba/panic-action %d
[media]
comment = public share
path = /mnt/media_files
force user = nobody
force group = nogroup
read only = No
create mask = 0777
directory mask = 0777
guest ok = Yes
[webroot]
comment = Apache web root folder
path = /var/www
valid users = jon
force user = jon
read only = No
create mask = 0777
directory mask = 0777
guest ok = Yes

testparm(its shows all config values that are not default) – aatdark Sep 10 '10 at 23:41