CentOS linux關閉iptables防火牆(Linux中的防火牆叫iptables)

來源:互聯網
上載者:User

標籤:防火牆   linux   

linux伺服器下防火牆為iptables組件,在安裝一些軟體的時候,iptables防火牆會阻止我們一些必要的串連。

查看iptables狀態:service iptables status
iptables開機自動啟動:    開啟: chkconfig iptables on     關閉: chkconfig iptables offiptables關閉服務:    開啟: service iptables start     關閉: service iptables stop 
重啟防火牆服務:service iptables restart

臨時關閉防火牆

首先執行臨時關閉防火牆操作,在此操作之前我們需要進入root許可權進行下面的操作,如果你不使用root許可權的話,會提示錯誤。

關閉防火牆必須在root許可權下

如果不在root許可權下,則先輸入su命令,斷行符號後輸入root的密碼,登入root許可權下的介面後輸入service iptables stop

當然關閉之前我們需要看看防火牆是否開啟在進行相關操作,命令跟關閉命令類似,只不過是把stop換成了status即:service iptables status

永久關閉防火牆

以上的操作只是臨時關閉了防火牆而已,當你的電腦重新啟動的時候又會開啟,如果你想永久關閉防火牆,可以嘗試以下這種方法。

開啟終端,在root許可權下輸入chkconfig iptables off即可永久關閉防火牆,當然需要我們重啟才會生效。




CentOS linux關閉iptables防火牆(Linux中的防火牆叫iptables)

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.