vCloud Director 9.1: Install NFS – Part 4


At first, we need to prepare the virtual machine we are going to deploy the NFS Server. These are the characteristics of the virtual machine.

  • O.S: CentOS 7 (64-bit)
  • vCPU: 2
  • RAM: 8 GB
  • HDD: 16 GB

Next, we need to install these packages on the CentOS server with yum:.

#yum install nfs-utils

And them, we need to create the directory that will be shared by NFS.

#mkdir /nfs

Change the permissions of the folder as follows.

#chmod -R 755 /nfs #chown nfsnobody:nfsnobody /nfs

Next, we need to start the services and enable them to be started at boot time.

systemctl enable rpcbind
systemctl enable nfs-server
systemctl enable nfs-lock
systemctl enable nfs-idmap
systemctl start rpcbind
systemctl start nfs-server
systemctl start nfs-lock
systemctl start nfs-idmap

Next, we need to install nano to share the NFS directory over the network a follows.

#yum install nano

And them …

# nano /etc/exports

We will make two sharing points  /nfs. Edit the exports file as follows:

/nfs            *(rw,sync,no_root_squash,no_all_squash)

Finally, start the NFS service

# systemctl restart nfs-server

Again we need to add the NFS service override in CentOS 7 firewall-cmd public zone service as:

firewall-cmd --permanent --zone=public --add-service=nfs
firewall-cmd --permanent --zone=public --add-service=mountd
firewall-cmd --permanent --zone=public --add-service=rpc-bind
firewall-cmd --reload

 

Hoping you have enjoyed this post, see you next time.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s