ICode9

精准搜索请尝试: 精确搜索
首页 > 其他分享> 文章详细

NFS的注意事项

2021-12-27 13:02:01  阅读:142  来源: 互联网

标签:exports rw NFS 注意事项 line 共享 trusted


exports - NFS server export table

        /               master(rw) trusty(rw,no_root_squash)
       /projects       proj*.local.domain(rw)
       /usr            *.local.domain(ro) @trusted(rw)
       /home/joe       pc001(rw,all_squash,anonuid=150,anongid=100)
       /pub            *(ro,insecure,all_squash)
       /srv/www        -sync,rw server @trusted @external(ro)
       /foo            2001:db8:9:e54::/64(rw) 192.0.2.0/24(rw)
       /build          buildhost[0-9].local.domain(rw)

       The first line exports the entire filesystem to machines master  and  trusty.
       In addition to write access, all uid squashing is turned off for host trusty.
       The second and third entry show examples for wildcard hostnames and netgroups
       (this  is  the  entry  `@trusted').  The  fourth line shows the entry for the
       PC/NFS client discussed above. Line 5 exports the  public  FTP  directory  to
       every host in the world, executing all requests under the nobody account. The
       insecure option in this entry also allows clients  with  NFS  implementations
       that  don't  use a reserved port for NFS.  The sixth line exports a directory
       read-write to the machine 'server' as well as the  `@trusted'  netgroup,  and
       read-only  to  netgroup  `@external', all three mounts with the `sync' option
       enabled. The seventh line exports a directory to both an  IPv6  and  an  IPv4
       subnet. The eighth line demonstrates a character class wildcard match.

   exportfs - 管理NFS共享文件系统列表

<pre><b>选项</b> <b>(OPTIONS)</b>
<b>-a</b> 打开或取消所有目录共享。

<b>-o</b> <u style="text-decoration-style:single">options,...</u>
指定一列共享选项,与 <b>exports(5)</b> 中讲到的类似。

<b>-i</b> 忽略 <b>/etc/exports</b> 文件,从而只使用默认的和命令行指定的选项。

<b>-r</b> 重新共享所有目录。它使 /var/lib/nfs/xtab 和 /etc/exports 同步。 它将
/etc/exports 中已删除的条目从 /var/lib/nfs/xtab
中删除,将内核共享表中任何不再有效的条目移除。

<b>-u</b> 取消一个或多个目录的共享。

<b>-f</b> 在“新”模式下,刷新内核共享表之外的任何东西。
任何活动的客户程序将在它们的下次请求中得到 <b>mountd</b> 添加的新的共享条目。

<b>-v</b> 输出详细信息。当共享或者取消共享时,显示在做什么。
显示当前共享列表的时候,同时显示共享的选项。
</pre>

标签:exports,rw,NFS,注意事项,line,共享,trusted
来源: https://www.cnblogs.com/huluxia-fun/p/15735847.html

本站声明: 1. iCode9 技术分享网(下文简称本站)提供的所有内容,仅供技术学习、探讨和分享;
2. 关于本站的所有留言、评论、转载及引用,纯属内容发起人的个人观点,与本站观点和立场无关;
3. 关于本站的所有言论和文字,纯属内容发起人的个人观点,与本站观点和立场无关;
4. 本站文章均是网友提供,不完全保证技术分享内容的完整性、准确性、时效性、风险性和版权归属;如您发现该文章侵犯了您的权益,可联系我们第一时间进行删除;
5. 本站为非盈利性的个人网站,所有内容不会用来进行牟利,也不会利用任何形式的广告来间接获益,纯粹是为了广大技术爱好者提供技术内容和技术思想的分享性交流网站。

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有