CentOS 7一些常用配置
一、更改启动模式
背景:个人开发环境,安装了GNOME桌面,默认启动是图形化模式。
修改为命令行模式。
systemctl set-default multi-user.target
二、命令行模式下启动图形
startx 想重新打开命令行界面呢?
alt + ctrl +F1~F6 //这个方法尝试了下不好用
三、实时查看启动日志
默认是有图片覆盖在屏幕上的,我想看看为啥启动到哪一步了?(当然也可以在val/log/boot.log中看)
这里是修改为实时显示的方法。
1 vim /boot/grub2/grub.cfg
2 找到如下一行:
3 linux16 /vmlinuz-3.10.0-229.el7.x86_64 root=/dev/mapper/centos-root ro rd.lvm.lv=centos/root rd.lvm.lv=centos/swap crashkernel=auto rhgb quiet LANG=en_US.UTF-8
4 删除rhgb(redhat图形化启动)即可。 更优雅一些的方法:
1 vim /etc/default/grub
2 删除配置参数GRUB_CMDLINE_LINUX="rd.lvm.lv=centos/root rd.lvm.lv=centos/swap crashkernel=auto rhgb quiet"中的rhgb
3 执行grub2-mkconfig -o /boot/grub2/grub.cfg重新生成启动参数。
四、永久关闭SElinux
执行vim /etc/selinux/config,将文件中的enforcing改为disabled即可。
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=enforcing
# SELINUXTYPE= can take one of three two values:
# targeted - Targeted processes are protected,
# minimum - Modification of targeted policy. Only selected processes are protected.
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
五、关闭防火墙
关闭防火墙:
systemctl stop firewalld.service
启动防火墙:
systemctl start firewalld.service
禁止防火墙启动:
systemctl disable firewalld.service
CentOS 7一些常用配置的更多相关文章
- CentOS 6.5环境使用ansible剧本自动化部署Corosync + pacemaker环境及corosync常用配置详解
环境说明: 192.168.8.39 node2.chinasoft.com 192.168.8.42 node4.chinasoft.com 192.168.8.40 ansible管理服务器 19 ...
- VMware中安装CentOS7网络配置静态IP地址,常用配置和工具安装
VMware中安装CentOS7网络配置静态IP地址,常用配置和工具安装在阿里云开源镜像地址下载镜像Index of /centos/7.2.1511/isos/x86_64/http://mirro ...
- centOS学习part4:安装配置vsftp
0 上一章(http://www.cnblogs.com/souvenir/p/3875934.html)我们完成了对远程工具VNC的安装配置,接下来我们将安装另外一个常用工具:VSFTP. vsft ...
- 【转】CentOS 6 服务器安全配置指南
原文连接: CentOS 6 服务器安全配置指南(通用) Linux 是一个开放式系统,可以在网络上找到许多现成的程序和工具,这既方便了用户,也方便了黑客,因为他们也能很容易地找到程序和工具来潜入 L ...
- httpd2.4常用配置
author:JevonWei 版权声明:原创作品 httpd 2.4配置 切换使用的MPM Centos7:/etc/httpd/conf.modules.d/00-mpm.conf 启用要启用的M ...
- [转帖]CentOS 6 服务器安全配置指南(通用)
CentOS 6 服务器安全配置指南(通用) http://seanlook.com/2014/09/07/linux-security-general-settings/ 发表于 2014-09- ...
- Apache入门 篇(二)之apache 2.2.x常用配置解析
一.httpd 2.2.x目录结构 Cnetos 6.10 YUM安装httpd 2.2.x # yum install -y httpd 程序环境 主配置文件: /etc/httpd/conf/ht ...
- centos7-centos6常用配置对比
设置(CentOS 6 vs CentOS 7)系统常用配置 ysvinit vs Upstart vs Systemd) 常见设置: 字符集CentOS 6方法:/etc/sysconfig/i1 ...
- Centos 6/7 常用命令总结 (基础)
Centos 6/7 常用命令总结 (基础): 参考链接:https://www.cnblogs.com/linhaifeng/p/6045600.html 目录介绍: a) bin目录:用来存放常用 ...
随机推荐
- 查看linux的出错信息
先执行:dmesg -c > /dev/null 该命令是把之前的一些信息删除,-c选项表示:Clear the ring buffer after first printing its con ...
- [OrangePi] Installation on internal EMMC
Install the image on SD Card as described above Boot your Orange PI board from SD Card Run: sudo ins ...
- iBatis面试题
1) Ibatis中使用like ‘%#filedName#%’ 时,有什么问题? 在xml映射文件中,如果直接按如上写法,会报异常:java.sql.SQLException: Invalid ar ...
- jquery中的each用法以及js中的each方法实现实例
each()方法能使DOM循环结构简洁,不容易出错.each()函数封装了十分强大的遍历功能,使用也很方便,它可以遍历一维数组.多维数组.DOM, JSON 等等在javaScript开发过程中使用$ ...
- jQuery DataTable-JavaScript API
虽然大多数时候你的Javascript交互将通过使用datatable初始化对象作为描述在使用这个网站的部分,有时,你会发现它有用一些外部控制表.可以使用以下函数从jQuery.dataTable对象 ...
- cut DEMO
分割后得到列: cat /etc/passwd|head -n 5 | cut -d : -f 1,6
- svn搭建以及可能遇到的问题解决方案
Svn服务器的安装和配置 1.安装svn服务器端软件从镜像服务器或者YUM源下载安装SVN服务器软件:yum install subversion mkdir /usr/local/svn //创建S ...
- 11、Jsp加强/EL表达式/jsp标签
1 Jsp基础回顾 Jsp基础 1)Jsp的执行过程 tomcat服务器完成:jsp文件->翻译成java文件->编译成class字节码文件-> 构造类对象-> 调用方法 to ...
- C#:插件、框架
1.开源实体映射框架EmitMapper(http://www.cnblogs.com/wuhong/archive/2011/09/21/2184313.html) 2.ffmpeg.exe是一个源 ...
- sql 2000以及2005以上获取数据库中所有的表(不包括系统表)
---------------------------------------------------------------------------- --sql 2005以上数据库 --- 获取数 ...