深度阅读

How to mount an NFS share on a client machine?

作者
作者
2023年08月22日
更新时间
12.02 分钟
阅读时间
0
阅读量

To mount an NFS share on a client machine, you can use the mount command. Here are the general steps:

  1. Create a mount point directory on the client machine where you want to mount the NFS share. For example:
sudo mkdir /mnt/nfs-share
  1. Use the mount command to mount the NFS share. For example:
sudo mount -t nfs server_ip_address:/path/to/share /mnt/nfs-share

Here, server_ip_address is the IP address of the NFS server, and /path/to/share is the path to the directory that you want to share on the server. You’ll also need to specify the mount point directory that you created in the previous step.

  1. Verify that the share has been mounted by using the df command to display mounted file systems:
df -h

This will show you a list of mounted file systems, including the NFS share that you just mounted.

Note that you may need to modify the /etc/fstab file to ensure that the NFS share is mounted automatically on boot. You can add an entry to the file that specifies the NFS share to mount, the mount point directory, and any additional options. For example:

server_ip_address:/path/to/share /mnt/nfs-share nfs rw,sync,hard,intr 0 0

相关标签

博客作者

热爱技术,乐于分享,持续学习。专注于Web开发、系统架构设计和人工智能领域。