Skip to content

os-frr: No possibility to select specific IP address as BGP source if interface contains multiple IP #5362

@n3wtype

Description

@n3wtype

Describe the bug
No possibility to select specific ip address as a source of bgp sessions. If interface has multiple ip addresses address selection is undeterministic. This is causing bgp neighbor mismatches on both side of bgp session depending on which.

There is possibility to select source interface, but it does not guarantee any specific IP from interface to be used.
The "Local initiater IP field is not used for update-source statement in frr.

# grep neighbor.localip * -r
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/forms/dialogEditBGPNeighbor.xml:    <id>neighbor.localip</id>
net/frr/src/opnsense/service/templates/OPNsense/Quagga/sa_policies.conf:dst={{ neighbor.localip }}
net/frr/src/opnsense/service/templates/OPNsense/Quagga/sa_policies.conf:src={{ neighbor.localip }}


# grep update-source * -r
net/frr/src/opnsense/service/templates/OPNsense/Quagga/bgpd.conf: neighbor {{ peergroup.name }} update-source {{ physical_interface(peergroup.updatesource) }}
net/frr/src/opnsense/service/templates/OPNsense/Quagga/bgpd.conf: neighbor {{ neighbor.address }} update-source {{ physical_interface(neighbor.updatesource) }}

To Reproduce
Steps to reproduce the behavior:

  1. Go to "Routing/BGP/Neighbor"
  2. set "local initiater IP"
  3. specified address is not used in frr config as value of update-source for given neighbor

Expected behavior
When "Local initiater IP" field is set, update-source within frr confguration should contain this IP, not an interface name. "Local initiater IP" should take precedence over source interface

Environment
OPNsense 26.1.5-amd64
FreeBSD 14.3-RELEASE-p9
OpenSSL 3.0.19

Metadata

Metadata

Assignees

No one assigned

    Labels

    incompleteIssue template missing info

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions