{"id":285,"date":"2018-03-10T00:00:32","date_gmt":"2018-03-09T16:00:32","guid":{"rendered":"https:\/\/cloudbool.com\/archive\/?p=285"},"modified":"2018-03-10T00:00:32","modified_gmt":"2018-03-09T16:00:32","slug":"centos7-stop-disable-firewall","status":"publish","type":"post","link":"https:\/\/cloudbool.com\/archive\/centos7-stop-disable-firewall.html","title":{"rendered":"CentOS7\u5173\u95ed\u9632\u706b\u5899"},"content":{"rendered":"<p>\u6709\u7684\u65f6\u5019\u6211\u4eec\u53ea\u662f\u9700\u8981\u6d4b\u8bd5\u4e00\u4e9b\u7b80\u5355\u7684\u7a0b\u5e8f\uff0c\u4f46\u662f\u7531\u4e8e\u9632\u706b\u5899\u7684\u5b58\u5728\uff0c\u9700\u8981\u653e\u884c\u6211\u4eec\u6307\u5b9a\u7684\u7aef\u53e3\uff0c\u5982\u679c\u4e00\u4e2a\u4e00\u4e2a\u53bb\u653e\u884c\u5b9e\u5728\u662f\u9ebb\u70e6\uff0c\u5bf9\u4e8e\u4e00\u4e9b\u6d4b\u8bd5\u670d\u52a1\u5668\u60c5\u51b5\uff0c\u53ef\u80fd\u6211\u4eec\u4e0d\u9700\u8981\u90a3\u4e48\u4e25\u683c\u7684\u5b89\u5168\uff0c\u7d22\u6027\u76f4\u63a5\u628a\u9632\u706b\u5899\u5173\u95ed\u3002<br \/>\n<!--more--><br \/>\n\u548cCentOS6\u7565\u6709\u5dee\u522b\uff0cCentOS7\u4e2d\u9632\u706b\u5899\u547d\u4ee4\u3001\u8fdb\u7a0b\u53ca\u76f8\u5173\u5305\u540d\u6539\u6210\u4e86<strong><em>firewall<\/em><\/strong>\uff0c\u5173\u95ed\u547d\u4ee4\u4e5f\u6709\u4e00\u70b9\u5dee\u522b\u3002<\/p>\n<h3>CentOS7\u5173\u95ed\u9632\u706b\u5899<\/h3>\n<pre><code>systemctl stop firewalld  #\u5173\u95ed\nsystemctl disable firewalld  #\u53d6\u6d88\u5f00\u673a\u542f\u52a8\n<\/code><\/pre>\n<h3>CentOS7\u9632\u706b\u5899\u653e\u884c\u7aef\u53e3<\/h3>\n<pre><code>firewall-cmd --permanent --add-port=80\/tcp\nfirewall-cmd --reload\n<\/code><\/pre>\n<p>\u5176\u4e2d80\u4e3a\u9700\u8981\u5f00\u653e\u7684\u7aef\u53e3\u53f7\uff0c<strong><em>&#8211;permanent<\/em><\/strong>\u662f\u6c38\u4e45\u5f00\u653e\uff0c\u5982\u679c\u53ea\u662f\u4e34\u65f6\u5f00\u653e\u4e00\u4e0b\uff0c\u53ef\u4ee5\u4e0d\u52a0\u8fd9\u4e2a\u53c2\u6570\u3002\u540e\u9762\u7684\u662f\u534f\u8bae\u7c7b\u578b\uff0c\u5f00\u653e\u4e4b\u540e\u8fd8\u9700\u8981\u91cd\u65b0\u52a0\u8f7d\u4e00\u4e0b\u624d\u80fd\u751f\u6548\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6709\u7684\u65f6\u5019\u6211\u4eec\u53ea\u662f\u9700\u8981\u6d4b\u8bd5\u4e00\u4e9b\u7b80\u5355\u7684\u7a0b\u5e8f\uff0c\u4f46\u662f\u7531\u4e8e\u9632\u706b\u5899\u7684\u5b58\u5728\uff0c\u9700\u8981\u653e\u884c\u6211\u4eec\u6307\u5b9a\u7684\u7aef\u53e3\uff0c\u5982\u679c\u4e00\u4e2a\u4e00\u4e2a\u53bb\u653e\u884c\u5b9e\u5728\u662f &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"\" href=\"https:\/\/cloudbool.com\/archive\/centos7-stop-disable-firewall.html\"> <span class=\"screen-reader-text\">CentOS7\u5173\u95ed\u9632\u706b\u5899<\/span> \u67e5\u770b\u5168\u6587 &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"footnotes":""},"categories":[182],"tags":[17,193],"class_list":["post-285","post","type-post","status-publish","format-standard","hentry","category-linux","tag-centos","tag-firewall"],"_links":{"self":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/285","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/comments?post=285"}],"version-history":[{"count":0,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/285\/revisions"}],"wp:attachment":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/media?parent=285"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/categories?post=285"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/tags?post=285"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}