Nuffnang

Sunday, April 17, 2011

Samba 3.5.8 : How do you install and set up Samba in linux? [Redhat Enterprise(RHEL), CentOS, Fedora]

Setting up Samba “can” be complicated at times. Especially if you are looking for instructions online where there are WAY too many tutorials which go in to details about what configuration does what, etc. Well, this post is nothing like that. Here

Here are quick and easy way to install Samba, configure it, and set up the drive letter on your XP/Vista. NOTE: for using Samba with Vista, please see my previous post in which I talk about changing settings in Vista so you can connect to your Samba share: Windows Vista Installation

Installing Samba (using yum on CentOS and Fedora): yum install samba
Installing Samba (using rpm):

1. Obtain Samba rpm from rhn.redhat.com
2. rpm -ivh samba*.rpm

Configuring Samba:
cd /etc/samba
mv smb.conf smb.conf.backup
vi smb.conf

Paste content below in to your vi:

[global]
workgroup = wrkgrp
netbios name = smbserver
security = SHARE
load printers = No
default service = global
path = /home
available = No
encrypt passwords = yes
[share]
writeable = yes
admin users = smbuser
path = /home/share
force user = root
valid users = smbuser
public = yes
available = yes

save and exit

adduser smbuser #add unix account
passwd smbuser #set unix account password
smbpasswd -a smbuser #lets create same user account on samba

/etc/init.d/smb restart

Now let us setup drive letter on our Windows so we can easily access these files.

Start -> run -> cmd

At the prompt type: net use z: \\ip_of_your_samba_server\share /user: smbuser password_you_assigned

That is it! At this point you have successfully set up Samba under Linux and are now successfully connected to your share from your Windows machine.

No comments:

Post a Comment