LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 09-01-2023, 03:54 PM   #1
james000
Member
 
Registered: Sep 2018
Posts: 143

Rep: Reputation: 2
Bonding not working on ubuntu


I have Ubuntu 20.04.6 LTS, physical server. I have bonding on this which is not working as expected, where I am looking for some help.
When ens10f0 is active in bond0.38, I can ping gw 10.72.38.1
When ens10f1 is active in bond0.38, I can't ping gw 10.72.38.1. As per network guy and tcpdump, ICMP is not going out of server, so it must be something on server config side, and not on network side.
Is there anything I am missing in this config, or any step, how should I troubleshoot further?
Code:
root@ubuntu-dsk3:~# cat /etc/netplan/00-installer-config.yaml
# This is the network config written by 'subiquity'
network:
  version: 2
  renderer: networkd

  ethernets:
    ens10f0:
      dhcp4: false
      dhcp6: false
    ens10f1:
      dhcp4: false
      dhcp6: false

  bonds:
    bond0:
      dhcp4: false
      interfaces:
        - ens10f0
        - ens10f1
      parameters:
        mode: active-backup
        primary: ens10f1
        mii-monitor-interval: 1
        gratuitious-arp: 5


  vlans:
    bond0.38:
      dhcp4: false
      addresses: [10.72.38.30/24]
      gateway4: 10.72.38.1
      id: 38
      link: bond0
      nameservers:
        addresses: [208.67.222.123, 208.67.220.123]
      routes:
        - to: default
          via: 10.72.38.1
root@ubuntu-dsk3:~# cat /proc/net/bonding/bond0
Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)

Bonding Mode: fault-tolerance (active-backup)
Primary Slave: ens10f1 (primary_reselect always)
Currently Active Slave: ens10f1
MII Status: up
MII Polling Interval (ms): 200
Up Delay (ms): 0
Down Delay (ms): 0
Peer Notification Delay (ms): 0

Slave Interface: ens10f1
MII Status: up
Speed: 25000 Mbps
Duplex: full
Link Failure Count: 0
Permanent HW addr: 88:e9:a4:5a:31:63
Slave queue ID: 0

Slave Interface: ens10f0
MII Status: up
Speed: 25000 Mbps
Duplex: full
Link Failure Count: 0
Permanent HW addr: 88:e9:a4:5a:31:62
Slave queue ID: 0
root@ubuntu-dsk3:~#
Thanks
 
Old 09-02-2023, 12:42 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Mode "active-backup" should work without configuring the switch, I have never tried this mode, perhaps it is working the way it is intended to work, but you are expecting something else? Note there are seven modes of bonding, perhaps you want one of balancing modes instead?

Quote:
Originally Posted by Bonding Manual about active-backup mode
Only one port is in the active state, and the other ports are in the backup state. From the outside, the MAC address of the bond is unique to avoid confusing the switch.
 
Old 09-02-2023, 03:02 PM   #3
james000
Member
 
Registered: Sep 2018
Posts: 143

Original Poster
Rep: Reputation: 2
Quote:
Originally Posted by Emerson View Post
Mode "active-backup" should work without configuring the switch, I have never tried this mode, perhaps it is working the way it is intended to work, but you are expecting something else? Note there are seven modes of bonding, perhaps you want one of balancing modes instead?
We want to keep these set of servers in "active-backup" mode. That means, if ens10f0 is primary, it should keep working as expected and then this fails, server should still work with ens10f1 because traffic failed over to ens10f1 now.
To test this, I changed primary from ens10f0 to ens10f1 and did "netplan apply", and immediately I lost ssh connectivity to server. Also ping to default gateway also stopped.
Then only option to ssh to server is, login to another server in same network and ssh to this affected one.
Yes, mac will remain same for bond0, which was created with ens10f0 and ens10f1 in "active-backup" mode.
Code:
bond0: <BROADCAST,MULTICAST,MASTER,UP,LOWER_UP> mtu 1500 qdisc noqueue master ovs-system state UP group default qlen 1000
    link/ether 32:40:0b:21:20:bb brd ff:ff:ff:ff:ff:ff
    inet6 fe80::3040:bff:fe21:20bb/64 scope link
       valid_lft forever preferred_lft forever
bond0.38@bond0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 32:40:0b:21:20:bb brd ff:ff:ff:ff:ff:ff
    inet 10.72.38.30/24 brd 10.72.38.255 scope global bond0.38
       valid_lft forever preferred_lft forever
    inet6 fe80::3040:bff:fe21:20bb/64 scope link
       valid_lft forever preferred_lft forever
 
  


Reply

Tags
ubuntu 20.04



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Is bond0 ready and a bonding interface? - Bonding Problems (RPI) Elliottlc Linux - Networking 6 10-24-2014 06:04 AM
Is bond0 ready and a bonding interface? - 4G Bonding Router Problems Elliottlc Linux - Networking 5 10-22-2014 02:37 PM
bonding bonding-xor and bonding-alb Chrysalis Linux - Networking 1 10-24-2009 02:14 PM
bonding and vlans. Bonding a vlan interface vs applying vlans to a bond interface JasonCzerak Linux - Networking 0 09-11-2008 09:59 AM
Infiniband Bonding and Ethernet Bonding edcrozer Linux - Networking 0 11-07-2007 03:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 04:03 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration