新建一个新的Linux虚拟机需要配置的东西
配置mac地址
Ubuntu 18.04 临时修改mac
# 关闭网卡
/sbin/ifconfig eth0 down
# 更改mac地址
/sbin/ifconfig eth0 hw ether xx:xx:xx:xx:xx:xx
# 启动网卡
/sbin/ifconfig eht0 upip link set eth0 down
ip link set eth0 address xx:xx:xx:xx:xx:xx
ip ling set eth0 upUbuntu 18.04 永久修改mac
pre-up ifconfig eth0 hw ether xx:xx:xx:xx:xx:xxUbuntu 20.04 修改mac
配置静态IP
Centos
Ubuntu
关闭selinux
查看状态
临时关闭
永久关闭
防火墙
使用iptables关闭防火墙(centos6)
使用firewalld关闭防火墙(centos7)
将firewall替换为传统的iptables
使用ufw关闭防火墙(ubuntu20.04)
配置hostname
配置root用户
配置ssh
配置ssh root用户登录策略

配置时钟同步
最后更新于