Page MenuHomeVyOS Platform

Removing interface from bridge results in error & config / system state mismatch
Closed, ResolvedPublicBUG

Description

Hi,
Fresh install of 1.1.8 throws a perl error when attempting to remove an interface from a bridge-group. The interface is removed from the bridge, but the configuration isn't changed to reflect this, resulting in the interface being re-added at next reboot

vyos@vyos:~$ show bridge
bridge name     bridge id               STP enabled     interfaces
br0             0000.128a38ead978       no              eth1
vyos@vyos:~$ configure
[edit]
vyos@vyos# delete interfaces ethernet eth1 bridge-group bridge br0 
[edit]
vyos@vyos# commit
[ interfaces ethernet eth1 bridge-group ]
Use of uninitialized value $newbridge in string ne at /opt/vyatta/sbin/vyatta-bridge.pl line 88.
Use of uninitialized value $newbridge in concatenation (.) or string at /opt/vyatta/sbin/vyatta-bridge.pl line 89.
Moving interface eth1 from br0 to 
Use of uninitialized value $bridge in concatenation (.) or string at /opt/vyatta/sbin/vyatta-bridge.pl line 98.
Incorrect number of arguments for command
Usage: brctl addif <bridge> <device>    add interface to bridge

[[interfaces ethernet eth1]] failed
Commit failed

Steps to reproduce:

  1. Create a bridge, brX, and add ethY to it
  2. Commit, save, and exit from configure mode
  3. Attempt to remove ethY from brX

See attached files for detailed output:

EDIT - sanitized show tech-support output, not enough coffee this morning

Details

Version
1.1.8

Event Timeline

syncer changed the task status from Open to In progress.Feb 27 2018, 2:51 PM
syncer triaged this task as Normal priority.
syncer subscribed.

@pers.edwin does this happens on 1.2 too?

Nope, tested both the vrrp (999.201711150853) and frr (999.201711012230) builds with the same configuration commands as I ran on 1.1.8 and it drops the bridge member properly.

However, I do see that the parent bridge-group config remains with that interface after committing the config:

ethernet eth1 {
    bridge-group {
    }
}

...but that entry is removed after a reboot.

see attached for details

syncer changed the task status from In progress to On hold.Oct 13 2018, 9:14 AM
syncer edited projects, added VyOS 1.2 Crux (VyOS 1.2.0-rc3); removed VyOS 1.1.x.

please retest on latest rolling

dmbaturin claimed this task.
dmbaturin subscribed.

The bug, as stated, is not reproducible in rc1.

dmbaturin@vyos# set interfaces ethernet eth4 bridge-group bridge br0
[edit]
dmbaturin@vyos# commit
[ interfaces ethernet eth4 bridge-group ]
Adding interface eth4 to bridge br0

[edit]
dmbaturin@vyos# run show bridge 
bridge name     bridge id               STP enabled     interfaces
br0             8000.0050569b18ed       no              eth4
                                                        vtun10
[edit]
dmbaturin@vyos# delete interfaces ethernet eth4 bridge-group 
[edit]
dmbaturin@vyos# commit
[ interfaces ethernet eth4 bridge-group ]
Removing interface eth4 from bridge br0

[edit]
dmbaturin@vyos# run show bridge 
bridge name     bridge id               STP enabled     interfaces
br0             8000.868abd1c912d       no              vtun10

Perhaps it was fixed by some of the earlier commits. I'm closing the task.