1. Temporarily turn off the firewall
[root@weizhu1 yum.repos.d]# service iptables stop
iptables: Setting chains to policy ACCEPT: filter [ OK ]
iptables: Flushing firewall rules: [ OK ]
iptables: Unloading modules: [ OK ]
2. Check the firewall status
[root@weizhu1 yum.repos.d]# service iptables statusiptables: Firewall is not running.
3. Permanently open the firewall
[root@weizhu1 yum.repos.d]# chkconfig iptables on
4. Permanently close the firewall
[root@weizhu1 yum.repos.d]# chkconfig iptables off
5. Temporarily open the firewall
[root@weizhu1 yum.repos.d]# service iptables start
disable selinux
[root@weizhu1 ~]# cd /etc/sysconfig/ #进入目录
[root@weizhu1 sysconfig]# ls #查看目录
atd cgred.conf grub ip6tables irqbalance netconsole ntpd readonly-root selinux sysstat.ioconf
auditd clock hsqldb ip6tables-config kdump network ntpdate rngd smartmontools system-config-firewall
authconfig console htcacheclean ip6tables.old kernel networking prelink rsyslog snmpd system-config-firewall.old
autofs cpuspeed httpd iptables keyboard network-scripts quota_nld samba snmptrapd system-config-users
cbq crond i18n iptables-config libvirt-guests nfs raid-check sandbox sshd udev
cgconfig firstboot init iptables.old modules nspluginwrapper readahead saslauthd sysstat wpa_supplicant
[root@weizhu1 sysconfig]# vi selinux #编辑selinux
[root@weizhu1 sysconfig]#
SELINUX=disabled #禁用selinux