Configure Samba on Solaris 10
What is Samba?
Samba is an open source/free software suites that provides seamless file and print service to SMB/CIFS clients. It allows interoperability between UNIX/LINUX servers and windows based clients.
Steps to configure Samba
1. First find out which version of Samba is installed.
# /usr/sfw/bin/smbstatus
Samba version 3.0.37
2. Next create a new user account
# useradd -u 40022 -g staff -d /export/home/DocXP -m -s /usr/bin/sh DocXP
This command will create user DocXP
# passwd DocXP
3. Next step is to look for smb configuration file. Copy the sample file to smb.conf file.
# cp /etc/sfw/smb.conf-example /etc/sfw/smb.conf
4. Next step is to edit the smb.conf file.
We need to change the workgroup according to windows workgroup.Alos we need to give Server string. And also change log file log file=/usr/local/samba/var/log.%m to
log file= /var/log/samba/log.%m
At the end add the following line to the smb.conf file
# vi /etc/sfw/smb.conf
workgroup = WORKGROUP
server string = Samba server
log file = /var/log/samba/log.%m
[DocXP]
comment = Share document
path = /var/spool/XR/saved
valid users = DocXP
browseable = yes
public = yes
writable = yes
printable = no
Save and quit.
In this file we edited the path which we going to share, the valid user and set the permission for share.
5. Next step is to change permission of log file of samba
# chmod 700 /var/log/samba
6. Also change the permission of the shared document .
# chmod 777 /var/spool/XR/saved
7. Now next step is to enable the samba server
# svcadm enable samba
# svcs -a samba
8. Now, we need to setup samba password to access from window system
# /usr/sfw/bin/smbpasswd -a DocXP
New SMB: password:
9. You can issue following command to query the workgroup
# /usr/sfw/bin/nmblookup WORKGROUP
10. Now next is to go to the window system. Open the RUN, and type the following command in it
\\IP-address-Samba-server\
It will prompt you for username and password . And you will see you are able to share the documents.

Leave a Reply