注册 登录
编程论坛 Linux教室

学习中。。。绑定双网卡,然后重启网络服务,一直报错,找不到原因,求大神指教,先谢过了

gerald1236 发布于 2019-06-19 15:38, 5178 次点击
network.service - LSB: Bring up/down networking
   Loaded: loaded (/etc/rc.d/init.d/network)
   Active: failed (Result: exit-code) since Wed 2019-06-19 15:15:57 CST; 17s ago
  Process: 3362 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=1/FAILURE)

Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 network[3362]: RTNETLINK answers: File exists
Jun 19 15:15:57 systemd[1]: network.service: control process exi...1
Jun 19 15:15:57 systemd[1]: Failed to start LSB: Bring up/down n....
Jun 19 15:15:57 systemd[1]: Unit network.service entered failed ....
Hint: Some lines were ellipsized, use -l to show in full.
1 回复
#2
606liutong2019-10-16 19:11
刚好前几天配过HPC 的服务器双网卡
reboot

#install team sofeware
yum install teamd -y
 
 
#Configuring teaming with nmcli
 
#check team configuration
nmcli con show
nmcli con delete ifcfg-enp6s0f0

#Next we create a team called 'team0'.
nmcli con add type team con-name team0
 
#Now if we show the connections again we should see team0 listed as device 'nm-team'.
nmcli con show
 
#This team is not yet doing anything, so we next add in our two interfaces.
nmcli con add type team-slave ifname enp6s0f0 master team0
nmcli con add type team-slave ifname enp6s0f1 master team0
 
 
cat /etc/sysconfig/network-scripts/ifcfg-team0
cat /etc/sysconfig/network-scripts/ifcfg-team-slave-enp6s0f0
cat /etc/sysconfig/network-scripts/ifcfg-team-slave-enp6s0f1
 
 
#add ip address to team0
nmcli con mod team0 ipv4.method manual
nmcli con mod team0 ipv4.addresses XX.XX.XX.XX/24
nmcli con mod team0 ipv4.gateway XX.XX.XX.XX
nmcli connection modify team0 ipv4.gateway "XX.XX.XX.XX"
nmcli connection modify team0 ipv4.method manual

--(如果Manual报错  则在team0中手动添加
--TEAM_CONFIG="{\"runner\": {\"name\": \"activebackup\"}}")

#Enabling the team
nmcli connection up team-slave-enp6s0f0
 
nmcli connection up team-slave-enp6s0f1
 
 
ip ad sh
 
 
teamdctl nm-team state

Service network restart
1