DEV Community

Shaikh Al Amin
Shaikh Al Amin

Posted on • Edited on

Create a Network File Share(NFS) in ubuntu machine and use it in your local machine

// Install NFS server on other machine

sudo apt-get update
sudo apt-get install nfs-kernel-server
Enter fullscreen mode Exit fullscreen mode

Update the etc exports:
Update the below home directory path which you want to share.

sudo nano /etc/exports
/home/jobayeer/Desktop/shared   *(rw,sync,no_subtree_check)
Enter fullscreen mode Exit fullscreen mode

*Now update all exports and allow from all host for now: *

sudo exportfs -a
Enter fullscreen mode Exit fullscreen mode

Edit allow hosts config like below:

sudo nano /etc/hosts.allow
ALL: ALL
Enter fullscreen mode Exit fullscreen mode

Now restart the server:

sudo systemctl start nfs-kernel-server
Enter fullscreen mode Exit fullscreen mode

*Use it on your own machine : *

sudo apt-get update
sudo apt-get install nfs-common

sudo mkdir /mnt/nfs_share


sudo mount 192.168.2.56:/home/jobayeer/Desktop/shared /mnt/nfs_share
Enter fullscreen mode Exit fullscreen mode

Top comments (0)

AWS Security LIVE!

Tune in for AWS Security LIVE!

Join AWS Security LIVE! for expert insights and actionable tips to protect your organization and keep security teams prepared.

Learn More

👋 Kindness is contagious

Dive into an ocean of knowledge with this thought-provoking post, revered deeply within the supportive DEV Community. Developers of all levels are welcome to join and enhance our collective intelligence.

Saying a simple "thank you" can brighten someone's day. Share your gratitude in the comments below!

On DEV, sharing ideas eases our path and fortifies our community connections. Found this helpful? Sending a quick thanks to the author can be profoundly valued.

Okay