Extended configurations in Amsterdam
May 4, 2023
Updated May 19, 2023

Setup Samba on CentOS

CentOS Samba

Using another OS?

Select the desired version or distribution.


Samba is a costless technology that allows data exchange without requiring additional software.

In this section, we look on configuration process in CentOS.

For supporting it, deploy additional components.

Initial, deploy programs by inserting:

sudo yum install samba samba-client samba-common


Afterward, it is necessary to modify config file /etc/samba/smb.conf.


sudo nano /etc/samba/smb.conf

That file contains many lines of code.
For application to start correctly, let s edit some of them.

Making shared catalogs

Making catalogs for file sharing is the next process.
Do it:

sudo mkdir /home/username/share1

Operating system support creation multiple directories for different users or groups.
The following is helped us to create a directory:

sudo mkdir /home/username/share1

Access settings

Access settings must be configured by adding the lines:


path = /home/username/share1

valid users = username

read only = no

Creating Users

To create Samba users, we use perform:

sudo smbpasswd -a username

Restart Samba

Finally, we restart the Samba service to apply the settings by typing:

sudo systemctl restart smb

You can now try to connect to shared folders from another computer on the network using the username and password you created earlier.


Samba is an excellent tool for sharing files and printers between computers on a local network. This article provides a comprehensive guide for setting up a Samba server on CentOS.

You may be also interested in

4 out of 5
Аverage rating : 4
Rated by: 1
1101 CT Amsterdam The Netherlands, Herikerbergweg 292
+31 20 262-58-98
700 300
700 300
We use cookies to make your experience on the Serverspace better. By continuing to browse our website, you agree to our
Use of Cookies and Privacy Policy.