We're here to assist with any of your needs, don't hestitate to reach out.
Samba is an open-source software suite that enables file and print services between different operating systems, including Windows, Linux, and macOS. It allows you to share files and printers with Windows clients on a Linux system.
Before installing Samba, it's recommended to update the system packages to their latest versions using the following command:
$ sudo apt update && sudo apt upgrade
To install Samba on Ubuntu 20.04, run the following command:
$ sudo apt install samba
After the installation, you need to configure Samba by editing the Samba configuration file. Open the file /etc/samba/smb.conf
using a text editor:
$ sudo nano /etc/samba/smb.conf
Within the file, you can define shared directories, access permissions, and other options. Make the necessary changes according to your requirements. Once you're done, save the file and exit the text editor.
After making the configuration changes, restart the Samba service using the following command:
$ sudo systemctl restart smbd
If you have UFW (Uncomplicated Firewall) enabled on your system, allow Samba traffic by running the following commands:
$ sudo ufw allow 139/tcp $ sudo ufw allow 445/tcp $ sudo ufw allow 137/udp $ sudo ufw allow 138/udp
Once Samba is installed and configured, you can access the shared directories from a Windows client by entering the Linux machine's IP address or hostname in the File Explorer's address bar.
What our customers say about us
Create your free account today.