{"id":1623,"date":"2017-01-21T13:06:58","date_gmt":"2017-01-21T05:06:58","guid":{"rendered":"http:\/\/www.youthtribe.com\/?p=1623"},"modified":"2017-01-21T13:15:04","modified_gmt":"2017-01-21T05:15:04","slug":"centos7-%e9%98%b2%e7%81%ab%e5%a2%99firewalld%e4%bd%bf%e7%94%a8%e6%96%b9%e6%b3%95%e6%b1%87%e6%80%bb","status":"publish","type":"post","link":"http:\/\/www.youthtribe.com\/archives\/1623","title":{"rendered":"centos7 \u9632\u706b\u5899firewalld\u4f7f\u7528\u65b9\u6cd5\u6c47\u603b"},"content":{"rendered":"
\u56e0\u4e3acentos7 \u7684\u9632\u706b\u5899\u9ed8\u8ba4\u7684\u662ffirewalld\u4e86\uff0c\u5982\u679c\u7528iptables\u7684\u8fd8\u662f\u81ea\u5df1\u5b89\u88c5\u3002\u4e2a\u4eba\u89c9\u5f97\u8fd8\u662f\u5e94\u8be5\u4e0e\u65f6\u4ff1\u8fdb\u4e00\u4e9b\u597d\uff0c\u76f4\u63a5\u62e5\u62b1\u65b0\u4e8b\u7269\u5427\u3002<\/p>\n
\u542f\u52a8\u4e00\u4e2a\u670d\u52a1\uff1asystemctl start firewalld.service
\n\u5173\u95ed\u4e00\u4e2a\u670d\u52a1\uff1asystemctl stop firewalld.service
\n\u91cd\u542f\u4e00\u4e2a\u670d\u52a1\uff1asystemctl restart firewalld.service
\n\u663e\u793a\u4e00\u4e2a\u670d\u52a1\u7684\u72b6\u6001\uff1asystemctl status firewalld.service
\n\u5728\u5f00\u673a\u65f6\u542f\u7528\u4e00\u4e2a\u670d\u52a1\uff1asystemctl enable firewalld.service
\n\u5728\u5f00\u673a\u65f6\u7981\u7528\u4e00\u4e2a\u670d\u52a1\uff1asystemctl disable firewalld.service
\n\u67e5\u770b\u670d\u52a1\u662f\u5426\u5f00\u673a\u542f\u52a8\uff1asystemctl is-enabled firewalld.service
\n\u67e5\u770b\u5df2\u542f\u52a8\u7684\u670d\u52a1\u5217\u8868\uff1asystemctl list-unit-files|grep enabled
\n\u67e5\u770b\u542f\u52a8\u5931\u8d25\u7684\u670d\u52a1\u5217\u8868\uff1asystemctl –failed<\/p>\n
3.\u914d\u7f6efirewalld-cmd<\/p>\n
firewall-cmd\u00a0–zone=\u00a0public\u00a0–remove-port=80\/tcp\u00a0–permanent<\/span><\/span><\/p>\n<\/div>\n centos7\u7684firewall-cmd\u600e\u4e48\u8ba9\u6307\u5b9aip\u80fd\u8bbf\u95ee\u6307\u5b9a\u7aef\u53e3\uff1f<\/p>\n<\/div>\n firewalld\u5982\u4f55\u5f00\u653e\u4e00\u4e2a\u7aef\u53e3\uff1f<\/p>\n<\/div>\n \u56e0\u4e3acentos7 \u7684\u9632\u706b\u5899\u9ed8\u8ba4\u7684\u662ffirewalld\u4e86\uff0c\u5982\u679c\u7528iptables\u7684\u8fd8\u662f\u81ea\u5df1\u5b89\u88c5\u3002\u4e2a\u4eba\u89c9\u5f97\u8fd8\u662f\u5e94\u8be5\u4e0e\u65f6\u4ff1\u8fdb\u4e00\u4e9b\u597d\uff0c\u76f4\u63a5\u62e5\u62b1\u65b0\u4e8b\u7269\u5427\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1,273],"tags":[278],"_links":{"self":[{"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/posts\/1623"}],"collection":[{"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/comments?post=1623"}],"version-history":[{"count":4,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/posts\/1623\/revisions"}],"predecessor-version":[{"id":1627,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/posts\/1623\/revisions\/1627"}],"wp:attachment":[{"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/media?parent=1623"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/categories?post=1623"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.youthtribe.com\/wp-json\/wp\/v2\/tags?post=1623"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}
\n
\n
\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n