最小化安装Linux初始配置
1.关闭firewalld
systemctl stop firewalld
systemctl disable firewalld
2.关闭seliunx(或兼容模式)
sed -i 's/SELINUX=.*/SELINUX=permissive/' /etc/selinux/config
setenforce 0
3.设置主机名
hostnamectl set-hostname xxxx
4.更换yum国内源、安装epel
yum install wget
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
wget -O /etc/yum.repos.d/epel-7.repo http://mirrors.aliyun.com/repo/epel-7.repo
yum clean all
yum makecache
5.配置基本环境:wget、net-tools、jdk、....
最小化安装Linux初始配置
最新推荐文章于 2024-07-08 17:01:55 发布