配置网络
1.连接有线网络
2.修改网卡配置文件
vi /etc/sysconfig/network-scripts/ifcfg-enp2s0f1
TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=dhcp # 选择dhcp
DEFROUTE=yes
NAME=enp2s0f1
DEVICE=enp2s0f1
ONBOOT=yes # 改为yes
3.重启network
service network restart
更换yum源
1.备份默认源
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
2.下载阿里云源
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
3.更新镜像源
# 清除缓存
yum clean all
# 生成缓存
yum makecache
安装ssh
1.安装OpenSSH服务器
yum install -y openssh-server
2.启动ssh服务
systemctl start sshd
3.设置开机启动
systemctl enable sshd
4.配置防火墙
firewall-cmd --permanent --add-service=ssh
firewall-cmd --reload
评论
匿名评论
隐私政策
你无需删除空行,直接评论以获取最佳展示效果