Centos 8前期装备
1、设置IP地址,最好固定IP地址,连接外网,配置dnf或yum代理
(建议后面不要更换IP,个别网页访问会失败)
#---------------------------------------------------------------------------------------------#
#centos 8 默认使用dnf代替了yum,原yum配置文件(/etc/yum.conf)默认链接到dnf配置文件(/etc/dnf/dnf.conf)
# vim /etc/dnf/dnf.conf
# 修改成如下[main] gpgcheck=1 installonly_limit=3 clean_requirements_on_remove=True #best=True proxy=http://Proxy_Ip:port proxy_username=username proxy_password=password
2、启动sshd(远程进去的话,一般默认跳过这步)
# systemctl enable sshd
# 开机自启
# systemctl start sshd
# 启用sshd
3、防火墙开发使用到的http协议端口
# firewall-cmd --permanent --add-service=http
——# 同 firewall-cmd --add-port=80/tcp --permanent
# 更加端口自行更改