CentOS7 关闭防火墙和selinux
本文将简单介绍在CentOS7上如何临时和永久关闭防火墙和selinux。
关闭防火墙
# 查看防火墙状态
[root@localhost ~]# systemctl status firewalld.service
● firewalld.service - firewalld - dynamic firewall daemon
Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
Active: active (running) since 二 2019-03-26 19:21:11 CST; 3 weeks 0 days ago
Main PID: 907 (firewalld)
CGroup: /system.slice/firewalld.service
└─907 /usr/bin/python -Es /usr/sbin/firewalld --nofork --nopid 3月 26 19:21:10 localhost.localdomain systemd[1]: Starting firewalld - dynam...
3月 26 19:21:11 localhost.localdomain systemd[1]: Started firewalld - dynami...
Hint: Some lines were ellipsized, use -l to show in full. # 临时关闭防火墙
[root@localhost ~]# systemctl stop firewalld.service # 禁止防火墙开机启动,永久关闭
[root@localhost 桌面]# systemctl disable firewalld.service
Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.
Removed symlink /etc/systemd/system/basic.target.wants/firewalld.service.
关闭Selinux
查看selinux状态
[root@localhost ~]# getenforce
Enforcing 临时关闭selinux
[root@localhost ~]# setenforce 0
[root@localhost ~]# getenforce
Permissive 永久关闭|禁止开机启动
进入到/etc/selinux/config文件
vim /etc/selinux/config
将SELINUX=enforcing改为SELINUX=disabled,重启生效。
CentOS7 关闭防火墙和selinux的更多相关文章
- Centos7关闭防火墙与selinux
CentOS 7.0默认使用的是firewall作为防火墙 直接关闭防火墙 systemctl stop firewalld.service #停止firewall systemctl disable ...
- CentOS7关闭防火墙和selinux
直接上命令 在root用户下 systemctl stop firewalld systemctl disable firewalld systemctl status firewalld vi /e ...
- centos7 关闭防火墙
centos7 关闭防火墙 1.firewall相关的操作 查看防火墙状态 firewall-cmd --state 关闭防火墙 systemctl stop firewalld.s ...
- CentOS 关闭防火墙和selinux
1)关闭防火墙(每个节点) [Bash shell] 1 2 service iptables stop chkconfig iptables off 2)关闭selinux(重启生效) [Bash ...
- Linux关闭防火墙、SELinux
使用root权限: Linux关闭防火墙: 1. chkconfig –list|grep iptables 2. chkconfig iptables off 永久关闭防火墙 3. chkconfi ...
- 永久关闭防火墙和selinux
临时关闭selinux: setenforce 0 //设置SELinux 成为permissive模式 彻底禁用selinux: 使用root用户,vim /etc/sysconfig/sel ...
- [RHEL7.1]关闭防火墙及SElinux
一.关闭防火墙 1. 先查看防火墙状态 [root@bogon ~]# 1 systemctl status firewalld firewalld.service - firewalld - dyn ...
- CentOS7 关闭防火墙[转]
CentOS6关闭防火墙使用以下命令, /临时关闭 service iptables stop //禁止开机启动 chkconfig iptables off CentOS7中若使用同样的命令会报错, ...
- centOS7关闭防火墙的命令
centOS7下关闭防火墙的命令已经改了,如下: systemctl stop firewalld
随机推荐
- MySQL数据库--外键约束及外键使用
什么是主键.外键关系型数据库中的一条记录中有若干个属性,若其中某一个属性组(注意是组)能唯一标识一条记录,该属性组就可以成为一个主键. 比如: 学生表(学号,姓名,性别,班级) 其中每个学生的学号是唯 ...
- A. Elections
链接 [http://codeforces.com/contest/1043/problem/A] 题意 有n个投票人已经投个对手ai票,让你求最小的k使得k-ai加起来大于,对手得票总和 分析 一个 ...
- c# 简易绘制C语言头文件包含关系图
最近在做一个项目的移植工作,项目很大,光c文件大约有1800多.由于某些需要,想要对某些代码文件引用的.h文件进行分析. 网上找了好久,暂无发现类似的工具. 正好,今天放假,就做了这么个工具. 好了, ...
- DPDK环境搭建及Helloworld样例
配置虚拟机环境 多张网卡,一张网卡是无法运行DPDK的,至少要两张. 多核CPU,可以在实现多个DPDK逻辑调度核lcore. DPDK依赖参考:http://www.cnblogs.com/vanc ...
- jdk命令行工具:jstat与jmap
转自文章:http://blog.csdn.net/gzh0222/article/details/8538727 C:\Users\Administrator\Desktop>jstat -g ...
- 如何自定义微信小程序swiper轮播图面板指示点的样式
https://www.cnblogs.com/myboogle/p/6278163.html 微信小程序的swiper组件是滑块视图容器,也就是说平常我们看到的轮播图就可以用它来做,不过这个组件有很 ...
- jmeter正则提取值 同级目录下的值
https://www.v2ex.com/api/nodes/show.json?name=python 接口返回: { "avatar_large": "//cdn.v ...
- CF1073E Segment Sum
数位DP,求[L,R]区间内所有"数字内包含的不同数码不超过k个的数字"之和.在状态上加一维状态压缩表示含有的数码集合.一开始读错题以为是求数字的个数.读对题之后调了一会儿. #i ...
- AJAX 原生态
AJAX 原生态 原生态AJAX详解和jquery对AJAX的封装 A ...
- Rabbitmq基本原理(转)
https://www.cnblogs.com/jun-ma/p/4840869.html