{"id":43001,"date":"2010-09-07T19:32:00","date_gmt":"2010-09-07T11:32:00","guid":{"rendered":"\/2010\/09\/7\/nfs-iptables.html"},"modified":"2010-09-07T19:32:00","modified_gmt":"2010-09-07T11:32:00","slug":"nfs-iptables","status":"publish","type":"post","link":"https:\/\/pangwenxin.com\/?p=43001","title":{"rendered":"\u5173\u4e8eNFS\u670d\u52a1\u5668\u4e0d\u5f97\u4e0d\u8bf4\u7684\u4e00\u4e2a\u95ee\u9898&#8211;\u9632\u706b\u5899"},"content":{"rendered":"<p>\u5982\u679cNFS\u670d\u52a1\u5668\u5728\u5185\u7f51\uff0c\u6ca1\u6709\u66b4\u9732\u5728\u5916\u7f51\u7684\u8bdd\uff0c\u9632\u706b\u5899\u5173\u95ed\u7684\u8bdd\uff0c\u914d\u7f6e\u8d77\u6765\u6ca1\u6709\u4ec0\u4e48\u95ee\u9898\uff0c\u4f46\u662f\u5982\u679c\u9700\u8981\u6253\u5f00\u9632\u706b\u5899\uff0c\u6bd4\u5982iptables\uff0c\u914d\u7f6e\u5b8c\u6bd5\u540e\u5ba2\u6237\u7aef\u6b63\u5e38\u60c5\u51b5\u4e0b\u662f\u8bbf\u95ee\u4e0d\u4e86nfs\u670d\u52a1\u7684\u3002<\/p>\n<p>NFS\u670d\u52a1\u7aef:SERVER<\/p>\n<p>\u5728\u5ba2\u6237\u7aef\uff1a<\/p>\n<p>showmount -e SERVER<\/p>\n<p>\u4f1a\u8fd4\u56de\u7c7b\u4f3c\u4e8eNo route to host.\u7684\u9519\u8bef\uff0c\u5c31\u662f\u56e0\u4e3a\u9632\u706b\u5899\u7684\u539f\u56e0\uff0c\u963b\u6321\u4e86RPC\u901a\u4fe1\u3002<\/p>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<p>\u9996\u5148\uff0c\u5728SERVER\u4e0a<\/p>\n<p><span style=\"font-size:x-small;\">&nbsp;vi \/etc\/sysconfig\/nfs<\/span><\/p>\n<p><span style=\"font-size:x-small;\">\u628aMOUNTD_PORT=892\u524d\u9762\u7684\u6ce8\u91ca\u53bb\u6389\uff0c\u4fdd\u5b58<\/span><\/p>\n<p>\u7136\u540e\uff0c\u5728SEVER\u4e0a\u4fee\u6539iptables<\/p>\n<p>\u6dfb\u52a0\u4ee5\u4e0b\u51e0\u6761<\/p>\n<p><span style=\"font-size:x-small;\">-A RH-Firewall-1-INPUT -p tcp -m state &#8211;state NEW -m tcp &#8211;dport 111 -j ACCEPT<br \/>-A RH-Firewall-1-INPUT -p udp -m state &#8211;state NEW -m udp &#8211;dport 111 -j ACCEPT<\/span><br \/><span style=\"font-size:x-small;\">-A RH-Firewall-1-INPUT -p tcp -m state &#8211;state NEW -m tcp &#8211;dport&nbsp;892 -j ACCEPT<br \/>-A RH-Firewall-1-INPUT -p udp -m state &#8211;state NEW -m udp &#8211;dport&nbsp;892 -j ACCEPT<\/span><br \/><span style=\"font-size:x-small;\">-A RH-Firewall-1-INPUT -p tcp -m state &#8211;state NEW -m tcp &#8211;dport&nbsp;2049 -j ACCEPT<br \/>-A RH-Firewall-1-INPUT -p udp -m state &#8211;state NEW -m udp &#8211;dport&nbsp;2049 -j ACCEPT<\/span><\/p>\n<p><span style=\"font-size:x-small;\">\u4fdd\u5b58\u3002<\/span><\/p>\n<p><span style=\"font-size:x-small;\">service iptables restart<\/span><\/p>\n<p><span style=\"font-size:x-small;\">service portmap restart<\/span><\/p>\n<p><span style=\"font-size:x-small;\">service nfs restart<\/span><br \/>\u5ba2\u6237\u7aef\u4e0a\uff1a<\/p>\n<p>service portmap restart<\/p>\n<p>\u4e8e\u662f\uff0cOK\u5566.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5982\u679cNFS\u670d\u52a1\u5668\u5728\u5185\u7f51\uff0c\u6ca1\u6709\u66b4\u9732\u5728\u5916\u7f51\u7684\u8bdd\uff0c\u9632\u706b\u5899\u5173\u95ed\u7684\u8bdd\uff0c\u914d\u7f6e\u8d77\u6765\u6ca1\u6709\u4ec0\u4e48\u95ee\u9898\uff0c\u4f46\u662f\u5982\u679c\u9700\u8981\u6253\u5f00\u9632\u706b\u5899\uff0c\u6bd4\u5982 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[33,50],"_links":{"self":[{"href":"https:\/\/pangwenxin.com\/index.php?rest_route=\/wp\/v2\/posts\/43001"}],"collection":[{"href":"https:\/\/pangwenxin.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pangwenxin.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pangwenxin.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pangwenxin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=43001"}],"version-history":[{"count":0,"href":"https:\/\/pangwenxin.com\/index.php?rest_route=\/wp\/v2\/posts\/43001\/revisions"}],"wp:attachment":[{"href":"https:\/\/pangwenxin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=43001"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pangwenxin.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=43001"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pangwenxin.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=43001"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}