Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Samba and login account issues.... 1

Status
Not open for further replies.

DCCoolBreeze

Programmer
Jul 25, 2001
208
US
I would like to setup samba so that when someone logs in they automatically have a directory in samba...one they do not have log in to. For example. I log into my account xyz on my Windows XP machine. One of my networked drives is my user drive (xyz) on he samba server. I have no need to login to the samba server and noone else can access that directory.

Anyone able to help??? I would really appreciate it.
 
I JUST got this to work on my samba server, logging in from win98 clients! It's not hard, but required lot's of research...
In your smb.conf:
[global]
workgroup = HOME
netbios name = LINUX
server string = Samba Server
encrypt passwords = Yes
obey pam restrictions = Yes
pam password change = Yes
passwd program = /usr/bin/passwd %u
passwd chat = *New*password* %n\n *Retype*new*password* %n\n *passwd:*all*authentication*tokens*updated*successfully*
unix password sync = Yes
log file = /var/log/samba/%m.log
max log size = 0
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
dns proxy = No
domain logons = yes
logon script=logon.bat
printing = lprng

[netlogon]
comment = Initialization Scripts
path=/home/netlogon
read only =yes
public = no
writeable = no
guest ok = no
browseable = yes
locking = no
force create mode = 0644
force directory mode = 0755

[homes]
comment = Home Directories
path = /home/%u
valid users = %S
read only = No
create mask = 0664
directory mask = 0775
browseable = No

[public]
comment = Public Directory
path = /home/public
browseable = yes
writable = yes
guest ok = yes
create mask = 0777
force create mode = 0777

Create a \public folder & a \netlogon folder under your \home folder. Chmod of the netlogon folder to 0755. \public (0777) will be for all users on your network. Create a logon.bat file with a dos editor that has this:
net use p: \\linux\public -y
net use h: /home -y

I created a group called users, added my users to it & chown the logon.bat to root/users with chmod = 0740 (not sure if this was nessecery).

Restart samba.

On the windows side:
Open properties of network neighborhood, properties of client for microsoft network. Be sure you have logon to windows network domain selected. In the windows domain box: home (this corresponds with what you have in the 'workgroup = ' in the smb.conf above.

That should do it. Have fun. Let me know if this works for you.
Keith
 
Hi,

Great info for using Win98 clients. Does anyone know how to get Win2K clients to work. I have been trying for weeks using all sort s on combinations. I remember reading somewhere about encrypted passwords and Win2K but I can't find it know.

Any help would be much appreciated. I really want to get Samba working.

Regards, Spoons.
Live is too short to panic. Take your time, breath and realise that you can do it. The answers are out there!
 
You probably need to set "encrypt passwords = yes" in the smb.conf file to get Win2K clients working.


ChrisP
 
I don't really understand what you are trying to do, but from my understanding is. I assume that you got samba install correctly.

1)You should create a group users if it not already created.
the cmmd is = groupadd users.
2)Next you should add user. the cmmd is = useradd username -G users.
3)Set the password = passwd username. Make sure the username and password are the same as the username and passwd that you are log on the the server.
4)Once you did all the above step go to the web broswer and type in http:\\your IP:901 to configure your samba and give it the permission you desire.
5)Finally you can map the drive. \\servername\username
 
Yep done that. I get the Linux server in the browser window and when I double click on the server i get the following

logon.jpg


I have checked that encrypted passwords are being used and that the username and password are set under Linux (which BTW is RH7.3) I have even re-installed RH7.3 several times over the past couple of weeks just in case.

It's probably something I'm missing out here.

Thank you in advance for any help.

Best regards, Spoons. Life is too short to panic. Take your time, breath and realise that you can do it. The answers are out there!
 

Hi fluid11 and phet,

It's worked.... :) at long last. Thank you for your help. It has taken weeks to get this going. Now it's clicked into place in the old grey cells, I'm happy. <Grin>

Off for a beer.

Thanks again.

Best regards, Spoons. Life is too short to panic. Take your time, breath and realise that you can do it. The answers are out there!
 
If you want the windows users to automatically have acces to the samba shares (without having to login specifically to samba) use: username map = /etc/samba/user.map in samba.conf That way, samba will log in the samba user based on the windows user & password.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top