Turn off firewall on Linux

Source: Internet
Author: User

I. Open/Close Firewall command under Linux 1) permanent, no recovery after restart: Chkconfig iptables on off: chkconfig iptables off 2) immediate effect, restart   restore:/etc/ Init.d/iptables start off:/etc/init.d/iptables stop  It is necessary to note that for other services under Linux, the above command can be used to perform the open and close operations.   When the firewall is turned on, do the following settings, open the relevant port,  modify the/etc/sysconfig/iptables file, add the following:  -a rh-firewall-1-input-m state-- State new-m tcp-p TCP--dport 80-j accept -a rh-firewall-1-input-m State--state new-m tcp-p TCP--dport 22-j accept   two. Ubuntu off firewall iptables-a input-i!   PPP0  -j accept three. CentOS Linux firewall configuration and shutdown execute the "Setup" command to start the text mode configuration Utility, select "Firewall Configuration" in "Select a tool", and then select the "Run Tool" button The firewall configuration interface appears, set the security level to disabled, and then select OK. or by command: #/sbin/iptables-i input-p tcp–dport 80-j accept#/sbin/iptables-i input-p TC P–dport 22-j accept#/etc/rc.d/init.d/iptables Save after you restart your computer, the firewall defaults to 80 and 22 ports. This should also not restart the computer: #/etc/init.d/iptables Restart shut down the Firewall service to:  View firewall information: #/etc/init.d/iptables Status Shutdown Firewall service: #/etc/init.d/iptables stop permanently closed? Do not know how a permanent method: #chkconfig--level iptables off  

Turn off the firewall under Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.