Samba Setup on CentOS 5


I have an existing user "amy" on my new installation of CentOS v5.1. I want a directory located at "/home/fileServer" to be shared through samba as "fileServer", that can be mounted by amy in Windows XP and Vista.

Here's the steps:

1. Installed samba server
yum install samba

2. Created directory to be shared
# mkdir /home/fileServer
# chown root:root /home/fileServer
# chmod 770 /home/fileServer

3. Edit samba configuration file
# cd /etc/samba
# mv smb.conf smb.conf.sample
# vi smb.conf
workgroup = MYWORKGROUP

comment = file server
path = /home/fileServer
writable = yes
create mask = 0770
directory mask = 0770

4. Edit samba user accounts
# smbpasswd -a root
# smbpasswd -a amy

5. Update smbusers file
# vi smbusers
root = administrator admin
amy = amy

6. Started smb daemon
# service smb restart

7. Test
In Windows XP, typed \\, and entered amy as user with the password. You should see the share defined in smb.conf.