centos6.6 shutting down firewalls and SELinux

Source: Internet
Author: User
Tags iptables

centos6.6 shutting down firewalls and SELinux

1. View firewall status

[email protected] ~]# Service iptables Status

Table: Filter

Chain INPUT (Policy ACCEPT)

Num Target prot opt source destination

1 ACCEPT All – 0.0.0.0/0 0.0.0.0/0 State related,established

2 ACCEPT ICMP--0.0.0.0/0 0.0.0.0/0

3 ACCEPT All--0.0.0.0/0 0.0.0.0/0

4 ACCEPT TCP--0.0.0.0/0 0.0.0.0/0 state NEW TCP dpt:22

5 REJECT All--0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited


Chain FORWARD (Policy ACCEPT)

Num Target prot opt source destination

1 REJECT All--0.0.0.0/0 0.0.0.0/0 reject-with icmp-host-prohibited


Chain OUTPUT (Policy ACCEPT)

Num Target prot opt source destination

2. Turn off firewall status

[[email protected] ~]# service iptables Stop

Iptables: Set the chain to policy accept:filter [OK]

Iptables: Clear Firewall rule: [OK]

Iptables: Uninstalling module: [OK]

[[Email protected] ~]# service iptables status

Iptables: Firewall is not running.

[[email protected] ~]# chkconfig iptables off //permanently shut down the firewall.


3. View SELinux Status

[Email protected] ~]# /usr/sbin/sestatus-v

SELinux status:enabled//indicates that SELinux has been started

SELINUXFS Mount:/selinux

Current mode:enforcing

Mode from config file:enforcing

Policy version:24

Policy from config file:targeted


4. Turn off SELinux to modify the startup configuration file

Vi/etc/selinux/config

Selinux=enforcing Change to Selinux=disabled

Reboot restart System

This article is from "Love_ Yao" blog, please be sure to keep this source http://20161215.blog.51cto.com/2276215/1782517

centos6.6 shutting down firewalls and SELinux

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.