内存2GB,CPU1核,硬盘80GB,CentOS7.8
- 安装过程语言选择:English-English(United States)
- Network打开
- time选择Shanghai并打开Network Time
- Language选择English-English(United States)
- Software Selection选择Minimal Install
- Installation destination,configuare partition,/boot分配512M,swap分配4096M,/分配剩余空间,Accept Changes
- root密码设置为123456
- 修改IP地址和主机名
vi /etc/sysconfig/network-scripts/ifcfg-ens33
BOOTPROTO="static"
IPADDR=192.168.39.10
NETMASK=255.255.255.0
GATEWAY=192.168.39.2
DNS1=192.168.39.2
systemctl restart network
hostnamectl status
hostnamectl set-hostname centos
- 关闭防火墙
systemctl status firewalld
systemctl stop firewalld
systemctl disable firewalld
- 修改hosts文件
vi /etc/hosts
192.168.39.10 centos
- 挂载阿里yum源
# 安装wget工具
yum -y install wget
# 备份原镜像文件
cd /etc/yum.repos.d/
rename .repo .repo.backup *
# 下载新镜像文件
wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo
# 修改镜像文件(非阿里云ECS用户)
sed -i -e '/mirrors.cloud.aliyuncs.com/d' -e '/mirrors.aliyuncs.com/d' /etc/yum.repos.d/CentOS-Base.repo
# 清除缓存
yum clean all
# 生成缓存
yum makecache
# 查看所有yum源
yum repolist all
# 更新所有包,软件,系统内核
# yum -y update
# 查看系统内核版本
# uname -r
# 查看系统内所有的内核
# rpm -q kernel
# 删除老旧内核
# yum remove -y xxxxxx
- 安装常用软件
yum install -y vim net-tools lrzsz unzip
- 关闭SELinux
sestatus
getenforce
setenforce 0
vi /etc/selinux/config
SELINUX=disabled
reboot
「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。




