Adding Users to Samba / CIFS
Once the /etc/samba/smb.conf file been configured, if the users/passwords on the client PCs differ from those on the Samba server then you'll need to add all the users from the client machines that will be connecting to the share(s). If you don't do this, the users on the clients will need to logon to the Samba server using a valid server user/password each time they connect to the share.
To do this, first add a user on the Samba server (-assuming one doesn't already exist) with the same name as that on the client with the following syntax:
sudo useradd -s /bin/true <remote username>
Once created, set the password for the new user to the same value as on the client using the following commands:
sudo smbpasswd -L -a <remote username>
sudo smbpasswd -L -e <remote username>
You will be prompted for a password: use the same password as that user has on the client. This is so the client can connect without being prompted for a specific user and password.
Note: try and keep the Linux and Windows users the same if possible. The object is to end up with the same users/passwords on the server as on the connecting clients