Installing and Configuring Samba in Ubuntu:

Samba is a free open source network software that uses SMB/CIFS protocol, created to provide secure, stable and fast file and print services for  clients in a network. The samba software also has graphical management software (gui) which helps with the configuration and management of samba clients.  In an ubuntu install, the software comes with a samba server configuration tool. This post will explain how to install a samba server in an ubuntu 11.04 lucid install, though the configuration can work in earlier version installs.

Installing Samba on Ubuntu:

1- Install Samba files

The first thing to do is open a terminal by selecting it from the Application-Accessories menu, and then paste or type the line below :

sudo apt-get  install  samba samba-common

2- In some cases you may run into python glade error or python-glade not being present. If that becomes the case type the line below on a terminal to install or upgrade python-glade package.

sudo apt-get install python-glade2

3- After which you are ready to install Samba Server configuration Tool:

Installing graphical interface system-config samba

sudo apt-get install system-config-samba

4- The next steps involves adding all the Linux users/samba users who you would like to access the samba service:

Add a Linux/Unix/samba user:

Tip: There are two different ways of adding users in linux. It is worth not to confuse them. for now this explanation shows how to add samba users using the samba software.

sudo smbpasswd -a user1
New SMB password:
Retype new SMB password:

5. After creating the users that would have rights to access the samba service, few security procedures are needed. This is important to enhance security that will affect who can and  can’t access the folders. The procedure can be done in a samba configuration script that automatically creates itself after install. While still using samba on a terminal open and

type.

sudo gedit /etc/samba/smb.conf

Find the following section and edit in the file:

####### Authentication #######

# “security = user” is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba-HOWTO-Collection/ServerType.html
# in the samba-doc package for details.
;  security = user

Uncomment the security line, and add another line to make it look like this:

security = user
username map = /etc/samba/smbusers

Advertisements

Comments are closed.

%d bloggers like this: