> For the complete documentation index, see [llms.txt](https://kawsing.gitbook.io/opensystem/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kawsing.gitbook.io/opensystem/andoid-shou-ji/untitled/share-nfs.md).

# Share NFS

建立共享目錄

<div align="left"><img src="/files/-Lp5j2i7mNhFJKCwiAYK" alt=""></div>

額外選項:subtree\_check,secure,no\_root\_squash

<div align="left"><img src="/files/-Lp5uybn25Xnt9fSO8R_" alt=""></div>

## NFS挂载的方法

```
sudo mkdir /NFS
mount -t nfs IP:/NFS /NFS
```

## umount  NFS 出現 device is busy。

解决方法：

1. 首先查找誰在占用：得到pid，kill -9 pid。

```
 sudo fuser /NFS
/NFS:                  317c
sudo kill -9 317
```

然后umount ,如不行 umount –f /NFS 强行卸載。

```
 sudo umount /NFS
```

```
# This configuration file is auto-generated.
# WARNING: Do not edit this file, your changes will be lost.
#
# /etc/exports: the access control list for filesystems which may be exported
#               to NFS clients.  See exports(5).
/export/schoolweb_home 120.115.2.0/24(fsid=1,rw,subtree_check,secure,no_root_squash)
/export/schoolweb_sites_enable 120.115.2.0/24(fsid=2,rw,subtree_check,secure,no_root_squash)
/export/schoolweb_sql 120.115.2.0/24(fsid=3,rw,subtree_check,secure,no_root_squash)
/export/schoolweb_www 120.115.2.0/24(fsid=4,rw,subtree_check,secure,no_root_squash)
# NFSv4 - pseudo filesystem root
/export 120.115.2.0/24(ro,fsid=0,root_squash,no_subtree_check,hide)
```
