Samba - add users
Go root: sudo bash First, add users to the system, its necessary: adduser <username> Fill in the password and some credentials. Add the user to Samba: smbpasswd -a <username> Then edit the user line in /etc/passwd The line looks like this: username:x:123:123:Username,,,:/home/username:/bin/bash Edit it so it does not have any home and will be logged out directly if trying to login on a terminal: username:x:123:123:Username,,,:/nonexistent:/bin/false Then remove the home of the user, be careful here to not make a typo: rm -rf /home/username Also edit /etc/samba/smb.conf and give user access if needed. Restart Samba, may not be necessary: service smbd restart
This is a personal note. Last updated: 2013-10-13 00:56:30.