1. View nfs service information
# svcs -a | grepnfs
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://img1.51cto.com/attachment/201309/28/703525_1380381515QPee.png "height =" 148 "/>
Note: It is not started by default.
2. Start and close the nfs service
(1) start the service in svcadm Mode
# Svcadm enable svc:/network/nfs/server: default # svcadm disable svc:/network/nfs/server: default or use the following method #/etc/init. d/nfs. server start #/etc/init. d/nfs. server stop
(2) configure the nfs Directory
# The actual discovery is not started directly. You can add the shared directory to the/etc/dfs/dfstab directory first and then start it.
# vi /etc/dfs/dfstabshare -F nfs -o rw /mnt
# Manual example of the share command
# share -F nfs -o rw=192.168.233.167 /mnt
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/23035A441-1.png "height =" 132 "/>
Start again
# /etc/init.d/nfs.server start
3. Related commands
(1) The share command displays nfs sharing information.
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/23035C252-2.png "height =" 90 "/>
(2) The dfshares command displays nfs sharing information.
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/23035C3a-3.png "height =" 81 "/>
View remote nfs server resources
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/23035B125-4.png "height =" 81 "/>
(3) unmount all cancels nfs sharing, and mount all nfs sharing on/etc/dfs/dfstab.
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/2303561934-5.png "height =" 181 "/>
4. Client Configuration
(1) manually mount the client
# mount 192.168.233.166:/mnt /mnt
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/23035645C-6.png "height =" 330 "/>
(2) mount the client at startup
# vi/etc/vfstab
650) this. width = 650; "style =" border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; "title =" image "border =" 0 "alt =" image "src =" http://www.bkjia.com/uploads/allimg/131227/2303561A8-7.png "height =" 207 "/>
# The usage of mount is the same as that of linux.
This article is from the "koumm linux technology blog" blog, please be sure to keep this source http://koumm.blog.51cto.com/703525/1303247