CentOS 7網絡卡網橋、繫結設定
一、網絡卡橋接設定
1、網絡卡配置檔案:
[[email protected] /]# vim /etc/sysconfig/network-scripts/ifcfg-enp8s0
TYPE=Ethernet
DEVICE=enp8s0
NAME=enp8s0
BOOTPROTO=none
ONBOOT=yes
BRIDGE=br0
2、網橋配置檔案:
[[email protected] /]# vim /etc/sysconfig/network-scripts/ifcfg-br0
TYPE=Bridge
DEVICE=br0
BOOTPROTO=static
ONBOOT=yes
IPADDR=192.168.1.200
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
DNS1=114.114.114.114
二、網絡卡繫結設定
1、網絡卡配置檔案01:
[[email protected] /]# vim /etc/sysconfig/network-scripts/ifcfg-enp6s0f0
TYPE=Ethernet
DEVICE=enp6s0f0
NAME=enp6s0f0
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond0
SLAVE=yes
2、網絡卡配置檔案02:
[[email protected] /]# vim /etc/sysconfig/network-scripts/ifcfg-enp6s0f1
TYPE=Ethernet
DEVICE=enp6s0f1
NAME=enp6s0f1
BOOTPROTO=none
ONBOOT=yes
USERCTL=no
MASTER=bond0
SLAVE=yes
3、網橋配置檔案:
[[email protected] /]# vim /etc/sysconfig/network-scripts/ifcfg-bond0
TYPE=Ethernet
DEVICE=bond0
BOOTPROTO=static
ONBOOT=yes
USERCTL=no
IPADDR=172.16.1.216
NETMASK=255.255.255.0
GATEWAY=172.16.1.1
DNS1=114.114.114.114