AWS, Cloud Computing

4 Mins Read

A Guide for Setting Up NFS Server and Client on Linux Servers

Voiced by Amazon Polly

Overview

Network File System (NFS) is a distributed file system protocol that allows sharing of files and directories across a network. This setup guide outlines the steps to configure an NFS server and client on Linux servers, enabling the sharing of resources between them. This can be especially useful for scenarios where multiple servers must efficiently access common data or storage resources.

Pioneers in Cloud Consulting & Migration Services

  • Reduced infrastructural costs
  • Accelerated application deployment
Get Started

Introduction

Network File System (NFS) is a distributed file system protocol that allows users to access remote files as if they were stored locally. This makes sharing files and folders across a network easy and can be a very efficient way to manage storage resources.

Prerequisites

  • Two Linux or Unix machines: One to act as the NFS server and the other as the NFS client.
  • Administrative access to both the server and client machines.
  • Basic knowledge of the Linux command line.
  • A network connection between the two machines.

Step-by-Step Guide

  1. NFS Server and Client Setup:

To configure NFS, you will need two Linux or Unix machines, one to act as the server and the other as the client.

step1

2. Login to Server

step2

3. Install NFS on Server

step3

  1. Now Enable and Start nfs-server and rpcbind:
  • rpcbind –This service converts Remote Procedure Call (RPC) program numbers to universal addresses. This service helps computers on the network to communicate with each other.

step4

  1. Be sure to enable inbound NFS traffic in the firewall:

If you are using AWS, allow inbound rule NFS to anywhere

step5

Or

step5b

step5c

  1. Now Create NFS Shared Directory

7. Grant NFS clients read, write, and execute permissions on the directory

step7

8. Now, export an NFS share directory

step8

9. Finally, export the filesystem and view the NFS Share

step9

10. Now Login to Client Account

step10

11. Create a mount directory

step11

12. Next, we will attach the NFS share to the mount folder that we just created in the server directory

To make the NFS share permanent, change the file that controls which file systems are mounted at boot

step12

step12b

13. On the server side, upload a file

step13

14. To check that the file is uploaded on the server side

step14

15. Now, finally, check to the client side

step15

Conclusion

We have now finished setting up NFS so that a computer (the client) can access files stored on another computer (the server). We did this by installing the NFS software on both computers, creating a shared directory on the server, and mounting the shared directory on the client. We then tested NFS by accessing a file on the server from the client.

Drop a query if you have any questions regarding NFS and we will get back to you quickly.

Making IT Networks Enterprise-ready – Cloud Management Services

  • Accelerated cloud migration
  • End-to-end view of the cloud environment
Get Started

About CloudThat

CloudThat is an official AWS (Amazon Web Services) Advanced Consulting Partner and Training partner, AWS Migration Partner, AWS Data and Analytics Partner, AWS DevOps Competency Partner, Amazon QuickSight Service Delivery Partner, AWS EKS Service Delivery Partner, and Microsoft Gold Partner, helping people develop knowledge of the cloud and help their businesses aim for higher goals using best-in-industry cloud computing practices and expertise. We are on a mission to build a robust cloud computing ecosystem by disseminating knowledge on technological intricacies within the cloud space. Our blogs, webinars, case studies, and white papers enable all the stakeholders in the cloud computing sphere.

To get started, go through our Consultancy page and Managed Services PackageCloudThat’s offerings.

FAQs

1. What is NFS?

ANS: – NFS, or Network File System, is a distributed file system protocol that allows users to access files over a network as if they were stored locally. NFS is a popular choice for file sharing between Unix and Linux systems, but it can also be used on other operating systems, such as Windows and macOS.

2. What are the benefits of using NFS?

ANS: – NFS offers several benefits, including:

  • Ease of use: NFS is easy to set up and use. Once the NFS server and client are installed and configured, users can access shared files as if they were stored locally.
  • Transparency: NFS is transparent to users, meaning they do not need to be aware that they are accessing files over a network.
  • Scalability: NFS is scalable to support many users and files.
  • Performance: NFS can provide good performance for most file sharing needs.

3. How do I set up NFS?

ANS: – To set up NFS, you must install the NFS server and client software on both the server and client computers. You must also configure the NFS server to export the directories you want to share. Once the server is configured, you can mount the shared directories on the client computers. For more detailed instructions on how to set up NFS, please see the documentation for your operating system.

WRITTEN BY Noopur Shrivastava

Noopur Shrivastava works as a Research Associate at CloudThat. She is focused on gaining knowledge of the Cloud environment. Noopur loves learning about new technology and trying out different approaches to problem-solving.

Share

Comments

    Click to Comment

Get The Most Out Of Us

Our support doesn't end here. We have monthly newsletters, study guides, practice questions, and more to assist you in upgrading your cloud career. Subscribe to get them all!