8
Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Embed Size (px)

Citation preview

Page 1: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Samba Server Configuration

Edit /etc/samba/smb.conf

Provide details in smb.conf file

Restart samba daemon by service smb restart

Contd slide 2

Page 2: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Details of windows share

Specify the windows workgroup in smb conf file

workgroup = WORKGROUPNAME

server string = BRIEF COMMENT ABOUT SERVER

Contd slide 3

Page 3: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Creation of samba share directory

To create a Samba share directory on your Linux server, add the following section to your smb.conf file

[sharename]

comment = Insert a comment here

path = /home/share/

valid users = tfox carole

public = no

writable = yes

printable = no

create mask = 0765

The above example allows the users tfox and carole to read and write to the directory /home/share, on the Samba server, from a Samba client.

Contd slide 4

Page 4: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Creation of samba share directory

To configure Samba on your Red Hat Linux system to use encrypted passwords, follow these steps:

Create a separate password file for Samba. To create one based on your existing /etc/passwd file, at a shell prompt, type the following command:

cat /etc/passwd | mksmbpasswd.sh > /etc/samba/smbpasswd

If the system uses NIS, type the following command:

ypcat passwd | mksmbpasswd.sh > /etc/samba/smbpasswd

The mksmbpasswd.sh script is installed in your /usr/bin directory with the samba package.

Change the permissions of the Samba password file so that only root has read and write permissions:

chmod 600 /etc/samba/smbpasswd Contd slide 5

Page 5: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Creation of samba share directory

The script does not copy user passwords to the new file. To set each Samba user's password, use the command (replace username with each user's username):shell prompt.

smbpasswd username

A Samba user account will not be active until a Samba password is set for it

Encrypted passwords must be enabled in the Samba configuration file. In the file smb.conf, verify that the following lines are not commented out:

encrypt password = yes

smb passwd file = /etc/samba/smbpasswd

Make sure the smb service is started by typing the command service smb restart at a shell prompt.

Contd slide 6

Page 6: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Using Nautilus App

To connect to a Linux Samba share from a Microsoft Windows machine, use Network Neighborhood or Windows Explorer.

To connect to a Samba share from a Linux system, from a shell prompt, type the following command:

smbclient //hostname/sharename -U username

You can also use Nautilus to view available Samba shares on your network. On the GNOME desktop, go to the Main Menu Button (on the Panel) => Programs => Applications => Nautilus to open a Nautilus window. Type smb: in the adress bar.

Contd slide 7

Page 7: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Using Nautilus App

If the SMB share you are connecting to requires a user name and password combination, you must specify them in the Location: bar using the following syntax (replace user, password, servername, and sharename with the appropriate values):

smb://user:password@servername/sharename/

End of the presentation

Page 8: Samba Server Configuration Edit /etc/samba/smb.conf Provide details in smb.conf file Restart samba daemon by service smb restart Contd slide 2

Thank You

Wish you all the best

For any clarification contact me at [email protected]