This is how I share directories from my main desktop computer at home running Fedora 23 with another computer I have at home running Lubuntu 14.04 LTS. That is to say, the former acts as server and the latter acts as client. As shown here, I also have a couple of public directories for exchanging files with anyone on the home network.
While configuring samba server and client, I found the official docs a bit difficult to comprehend with regards to a few things but when I went online to look at how others were doing, the quality of many of the guides and discussions I found were not very good so I wrote down what I did to get a proper setup.
Assuming your username is erikn
, the hostname of the server is cubi
,
that /home/erikn/Storage/
is the directory you want to share unlisted, read-only,
with authenticated clients, that you want /home/erikn/Storage/Public/
to be public,
read-only, guest-only and that you want /home/erikn/Storage/Public/Incoming/
to be
public, read-write, guest-only, these instructions show what to do. Modify as needed.
On server, execute
mkdir -p ~/Storage/Public/Incoming/
sudo smbpasswd -a erikn
sudo dnf install policycoreutils-python-utils
sudo semanage fcontext -a -t samba_share_t "/home/erikn/Storage(/.*)?"
sudo restorecon -R -v /home/erikn/Storage/
Update /etc/samba/smb.conf
of server as per attached file.
Update /etc/fstab
of client as per attached file.
On client, execute
sudo mount -a
That's it, we're done :)