Skip to content

[BUG] Disabling BGP in a VRF crashes ebgp.multihop configuration templates #2486

@ipspace

Description

@ipspace

Disabling BGP in a VRF results in a vdata.bgp data structure that has no neighbors (it only specifies the redistribution of connected routes into BGP). That mightily upsets ebgp.multihop configuration templates that expect to see bgp.neighbors whenever bgp is mentioned.

Lab topology

module: [ bgp, vrf ]
plugin: [ ebgp.multihop ]

vrfs:
  tenant:
    bgp: False
    links: [ dut-h1 ]

bgp.multihop.sessions:
- dut:
  pe2:

nodes:
  dut:
    bgp.as: 65000
  pe2:
    bgp.as: 65101
  h1:
    device: linux

links:
- dut-pe2

Proposed solution

As the final step in BGP module processing, make sure that the bgp data structure in every routing instance (if present) has bgp.neighbors list which can be empty.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions