1.基本网络配置
一般内容有:
主机名:hostname
IP:
路由:route
DNS服务器:主,次,第三DNS服务器
CentOS6之前:
#查看网卡
dmesg | grep -i eth
ethtool -i eth0
#卸载网卡驱动
modprobe -r e1000
rmmod e1000
#装载网卡驱动
modprobe e1000
#范例:临时修改网卡名称
[root@centos6 ~]# ip link set eth0 down
[root@centos6 ~]# ip link set eth0 name aa
[root@centos6 ~]# ip link set aa up
网卡配置方式:
- 静态指定:
ifconfig,route,netstat
ip: object{link,addr,route},ss,tc
system-config-network-tui,setup
- 动态分配:
DHCP:Dynamic Host Configuration Protocol