Network File System (NFS) is a client-server application that allows users to view and modify files on remote computers as if they were local files. NFS is one of several standards for distributed file systems on network attached storage (NAS). Behind the scenes, NFS uses remote procedure calls (RPC) to route client requests.
NFS allows users or administrators to mount all or part of a server's file system or a local device. On Linux or UNIX, you can do this by running the mount command while the terminal is pointing at a specific local folder. Clients can have read-only or read-write permissions assigned to folders or individual files.
In this article, you will learn:
NFS is a tried and tested protocol for remote file mounting, but there are alternatives, like FUSE, and the Windows SMB protocol, which can also be used on Linux systems. Below are some of the pros and cons of NFS.
NFS advantages
NFS disadvantages
There are currently three versions of NFS:
Using NFS with TCP
All versions of NFS support Transmission Control Protocol (TCP) over IP networks. Only NFSv4 requires it. NFSv2 and NFSv3 can alternatively use User Datagram Protocol (UDP) over IP networks, to establish stateless network connections between clients and servers.
TCP vs UDP
When using NFSv2 or NFSv3 over UDP, the overhead required by the UDP protocol is typically lower than TCP. This can improve performance on networks with high uptime and low congestion. However, UDP is stateless and the server crashes unexpectedly, UDP clients keep sending requests to the server, flooding the network with traffic.
In addition, in UDP if a client is missing a frame, it needs to resend the full RPC request, while with TCP, it only needs to retransmit the lost frame. Therefore, we recommend using TCP when connecting to an NFS server. Therefore, in most real-world scenarios, TCP is recommended.
Microsoft Azure, a popular public cloud service, offers Azure Files, a cloud-based distributed file which supports NFS 4.1 since September 2020, in the Azure Files premium tier only.
This means you can mount file shares from Azure Files storage just as easily as you would mount file shares from a server in the local data center, with the full semantics of a regular file system. Azure Files also supports strong consistency, enabling frequent updates by clients to their data.
To backup NFS shares, you can use tools like rsync, or third-party backup providers. Migration of large data volumes is managed with standard utilities like scp or rsync.
See the Azure documentation to learn how to create an NFS share in Azure Files.
Related content: Solve your Linux file service challenges in Azure
Azure NetApp Files is a cloud service offering enterprise-class, high-performance file storage for enterprises. It supports NFS versions 3.1 and onwards.
Azure NetApp Files supports all types of production workloads and provides built-in high availability. You can choose the level and performance of the service, and perform instant snapshots of your data.
Leverage industry-leading NetApp technology to migrate the most demanding Linux and Windows file workloads to Azure. Azure NetApp Files delivers sub-millisecond latency and equivalent performance to what you would achieve with a local bare metal server.
Azure NetApp Files provides three performance levels: Standard, Premium, and Ultra. You can provision file shares in any of the tiers with one click.
Azure NetApp Files integrates with complex business workloads such as SAP HANA, high performance computing (HPC), line of business (LOB) applications, and virtual desktop infrastructure (VDI). For these and many more enterprise workloads, it offers integrated data management and application awareness for backups and snapshots.
You can manage file shares using Azure Portal or CLI, PowerShell commands, or a REST API, just like any other Azure service. Azure NetApp Files supports multiple storage protocols in one service, including NFSv3, SMB3.1.x, and NFSv4.1. This allows you to transition workloads to the cloud in a “lift and shift” model, without requiring code changes.
When migrating large enterprise workloads, rsync data transfer is not enough. With Azure NetApp Files you can manage large-scale data transfer and synchronization at ease.
The service provides FIPS 140-2-compliant data encryption, role-based access control (RBAC), Active Directory authentication, and access control lists (ACL). Azure NetApp Files complies with major industry certifications such as HIPAA, SOC and GDPR. These and other enterprise-grade features mean you can migrate any enterprise workload to the cloud with complete confidence.
Want to get started? See Azure NetApp Files for yourself with a free demo.