Configuring file sharing between Linux machines is essential for networked environments where multiple users need to access files across different systems. This guide covers setting up two popular protocols: NFS (Network File System) and Samba/CIFS, on both Ubuntu and Arch Linux distributions.
Configuring NFS
Installation
- Ubuntu:
sudo apt install nfs-kernel-server - Arch Linux:
sudo pacman -S nfs-utils
Server Configuration
-
Export Directory: Edit
/etc/exportsto specify directories you want to share with clients. Example:/data/shared 192.168.1.0/24(rw,sync,root_squash,no_subtree_check) -
Restart NFS Service:
- Ubuntu:
sudo systemctl restart nfs-kernel-server - Arch Linux:
sudo systemctl restart nfs-server
- Ubuntu:
-
Verify Exports: Use
showmount -e <server-ip>to list exported directories.
Client Configuration
- Install NFS Utilities:
- Ubuntu:
sudo apt install nfs-common - Arch Linux:
sudo pacman -S nfs-utils
- Ubuntu:
2
Read the full article at DEV Community
Want to create content about this topic? Use Nemati AI tools to generate articles, social posts, and more.

![[AINews] The Unreasonable Effectiveness of Closing the Loop](/_next/image?url=https%3A%2F%2Fmedia.nemati.ai%2Fmedia%2Fblog%2Fimages%2Farticles%2F600e22851bc7453b.webp&w=3840&q=75)



