Centos7 deployment YUM NFS storage and sharing service (b)

NFS shared storage service


NFS: (Network File System) Network File System

1. depend on the RPC (remote procedure call)

2. To install nfs-utils, rpcbind package

3. System Services: nfs, rpcbind

4. Shared configuration file: / etc / exports


Specific steps to create NFS shared storage services


1. Create a disk formatted partition and mount to / mnt directory

image.png


2. Install nfs-utils rpcbind package

[root@promote ~]# yum install nfs-utils rpcbind -y

image.png



3. Modify the nfs service configuration file

[root@promote ~]# vim /etc/exports

image.png


4. Start Services

[root@promote ~]# systemctl start nfs

[root@promote ~]# systemctl start rpcbind

Micro-letter picture _20190907214728.png


5. Close the firewall

[root@promote ~]# systemctl stop firewalld.service 

[root@promote ~]# setenforce 0

image.png


6. own view / mnt directory is provided out

[root@promote ~]# showmount -e

image.png


7. Open the client virtual machine, turn off the firewall

[root@promote ~]# systemctl stop firewalld.service 

[root@promote ~]# setenforce 0

image.png


8. Install httpd service

[root@promote ~]# yum install httpd -y

image.png


9. Mount

[root@promote ~]# mount 192.168.100.128:/mnt /var/www/html

image.png


10. Review the capacity of the site

image.png


Added: modify the configuration file automatically mount

[root@promote ~]# vim /etc/fstab

image.png


Use mount -a to perform


Guess you like

Origin blog.51cto.com/14469918/2436501