-
Notifications
You must be signed in to change notification settings - Fork 10
/
nfs
54 lines (51 loc) · 1.34 KB
/
nfs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#server side configuration
30 yum install nfs-utils
31 mkdir /test1 /test2
32 cat /etc/selinux/config
33 getsebool -a |grep nfs
34 getsebool -a |grep nfs_export
35 setsebool nfs_export_all_ro=1
36 setsebool nfs_export_all_rw=1
37 getsebool -a |grep nfs_export
38 firewall-cmd --state
39 systemctl status firewalld.service walld
40 firewall-cmd --permanent --add-service=nfs
41 firewall-cmd --reload
42 systemctl enable rpcbind nfs-server
43 systemctl start rpcbind
44 systemctl start nfs
45 systemctl status rpcbind
46 systemctl status nfs
47 vi /etc/exports
48 man exportfs
49 exportfs -avr
50 cat /var/lib/nfs/etab
51 systemctl restart rpcbind
52 systemctl restart nfs
53 systemctl status rpcbind
54 systemctl status nfs
#client side
257 yum install nfs-utils
258 systemctl enable rpcbind
259 systemctl start rpcbind
260 systemctl status rpcbind
261 mkdir /test1
262 mkdir /test2
263 cat /etc/fstab
264 mount -t nfs -o rw 172.31.25.42:/test1 /test1
265 df -h
266 cd /test1/
267 ls
268 mount -t nfs 172.31.25.42:/test2 /test2
269 cd /test2
270 touch myfile
271 cd /test1
272 touch myfile1
273 ls
274 df -h
275 cd
276 vi /etc/fstab
281 umount /test1
282 umount /test2
283 mount -a
285 df -h