'ZDNET Recommends': What exactly does it mean?
ZDNET's recommendations are based on many hours of testing, research, and comparison shopping. We gather data from the best available sources, including vendor and retailer listings as well as other relevant and independent reviews sites. And we pore over customer reviews to find out what matters to real people who already own and use the products and services we’re assessing.
When you click through from our site to a retailer and buy a product or service, we may earn affiliate commissions. This helps support our work, but does not affect what we cover or how, and it does not affect the price you pay. Neither ZDNET nor the author are compensated for these independent reviews. Indeed, we follow strict guidelines that ensure our editorial content is never influenced by advertisers.
ZDNET's editorial team writes on behalf of you, our reader. Our goal is to deliver the most accurate information and the most knowledgeable advice possible in order to help you make smarter buying decisions on tech gear and a wide array of products and services. Our editors thoroughly review and fact-check every article to ensure that our content meets the highest standards. If we have made an error or published misleading information, we will correct or clarify the article. If you see inaccuracies in our content, please report the mistake via this form.
How to share files across your network from these popular Linux GUIs
I regularly share files and folders across my home network from Linux. In fact, I have one machine that houses a particular folder that is home to all of my first-draft manuscripts. When I decided I'd rather keep those files in-house (instead of risking a third-party cloud provider using them to train AI neural networks), Samba was the obvious solution.
Also: Linux kernel 6.8 offers some exciting new features and 'fixes all over'
For someone who has used Linux for decades, setting up a Samba share was a no-brainer. For those who are new to the open-source operating system, it's not quite as simple. Thankfully, two of the most popular Linux GUIs (GNOME and KDE Plasma) make it a bit easier to create such shares.
I want to walk you through the process of doing just that, so you can create network shares on your Linux machine with ease.
How to share files across your network from these Linux GUIs
First: Installing Samba
What you'll need: To make this work, you'll need a Linux distribution with either the GNOME or KDE Plasma desktop environments. You'll also need a user with sudo privileges. That's it. Let's make it happen. I'll demonstrate on a Ubuntu-based distribution (Pop!_OS). If you use a Fedora-based distribution, make sure to swap out apt-get for the dnf package manager during the Samba installation process.
1. Install Samba
In case your Linux distribution didn't ship with Samba pre-installed, you can install it with the command:
sudo apt-get install samba -y
If your distribution is Fedora-based, that command would be:
sudo dnf install samba -y
2. Add and enable your user for Samba access
By default, users need to be added and enabled for Samba usage. This only requires two commands. The first adds the user to Samba with this command (where USERNAME is your Linux username):
sudo smbpasswd -a USERNAME
You'll first be prompted for your sudo password and required to type and verify a password for Samba.
Also: BigLinux makes Linux easy for anyone - and it should be way more popular
Next, enable the user with the command (where USERNAME is your Linux username):
sudo smbpasswd -e USERNAME
Sharing from GNOME
1. Install the Nautilus extension
To make this work with the Natilus file manager (aka "Files"), you need to install a piece of software with the command:
sudo apt-get install nautilus-share -y
If your distribution uses dnf, that command is:
sudo dnf install nautilus-share -y
2. Restart Nautilus
You can restart Nautilus with the command:
nautilus -q
3. Share your folder
Open Nautilus and locate the folder you want to share. Right-click that folder and select Local Network Share.
4. Configure the share
In the resulting pop-up window, click the checkbox for Share this folder. Once you've done that, you can name the share, and then (if you want to give permission for users to alter the contents of the share) click the checkbox for "Allow others to create and delete files in this folder." If you want to allow anonymous logins to be able to access the share, you can click the checkbox for Guest access (although I wouldn't recommend that for security reasons).
Click Create Share and then, when prompted, click Add the permissions automatically. If you receive an error that includes "net usershare' returned error 255," you'll need to run the following two commands:
sudo mkdir -p /var/lib/samba/usershares/ sudo chmod go+rwx /var/lib/samba/usershares/
Once you've done that, you should be able to access the shared folder from your network.
Sharing from KDE Plasma
1. Install the filesharing component
Log into KDE Plasma and open the Konsole app. Issue the command:
sudo apt-get install kdenetwork-filesharing -y
If your distribution is based on Fedora, that command would be:
sudo dnf install kdenetwork-filesharing -y
Also: The top cloud storage services you can buy to protect your files
You'll then need to go through the same process outlined above for adding and enabling your users for Samba shares.
2. Open the Share tab for the folder to be shared
Right-click on the folder you want to share and click Properties. In the resulting pop-up, click on the Share tab.
3. Fix the permissions
At the top of the Share tab, you'll probably see a warning with a button marked Fix Permissions. Click that button. When prompted, click Change Permissions.
4. Enable the share
Back at the Share tab, click the checkbox for "Share this folder with other computers on the local network." Once you've done that, you can then configure the share by giving it a name and allowing/configuring guest access. I would suggest leaving Everyone with Read Only permissions and giving your user Full Control. Once you've done that, click OK.
Also: The first 5 Linux commands every new user should learn
Once you've done these steps, you can share any folder (so long as you have permission to access it) from your Linux machine to your network.