BGP/OSPF Integration
Integrating AthenaBNG into a core that is migrating from OSPF to IS-IS, with native dual-stack iBGP over the loopbacks.
Overview
AthenaBNG's control plane is built around two roles:
- IS-IS is the IGP and carries only the router loopback reachability.
- BGP carries subscribers and peers with the rest of the core over those loopbacks.
This page covers the interop story: how the BNG slots into an upstream that historically ran OSPF and is moving to IS-IS, and the FRR internals that implement it.
Reference topology
In the reference deployment the upstream/border routers are MikroTik boxes running OSPF as a legacy IGP, migrating to IS-IS. The BNG integrates by:
- speaking dual-stack IS-IS to the border routers to exchange loopback
reachability (IPv4
/32+ IPv6/128), and - running native IPv4 + IPv6 iBGP loopback-to-loopback for the subscriber and transit tables.
The IGP job is deliberately minimal: it exists so the loopbacks are reachable, which is all iBGP needs. Subscribers ride BGP, not the IGP.
MikroTik dual-stack IS-IS note
On MikroTik, dual-stack IS-IS is a single instance carrying both address
families (afi=ip,ipv6) — not two separate instances. This mirrors the BNG,
where routing.isis is one FRR router isis instance advertising both AFIs
(single-topology, metric-style wide). Keep both ends single-instance/dual-AFI so
the adjacency and metrics line up.
OSPF during migration
While the core still runs OSPF, the BNG can bring up routing.ospf alongside
IS-IS if it needs to exchange loopbacks with an OSPF-only neighbour during
transition. OSPF here redistributes the loopback (CONNECTED-TO-OSPF, matched to
interface lo) and static routes only — same loopback-carrier role as IS-IS.
Prefer IS-IS as the target IGP and retire OSPF once the core has migrated.
iBGP: loopback-to-loopback, native dual-stack
Both address families peer over the loopbacks with update-source lo:
routing:
bgp:
enabled: true
asn: 64512
neighbors:
- address: "10.255.0.1" # BDR1 v4 loopback
remote_as: 64512
description: "BDR1 iBGP v4"
update_source: "lo"
- address: "2001:df4:2040::1" # BDR1 v6 loopback
remote_as: 64512
description: "BDR1 iBGP v6"
update_source: "lo"
FRR renders two peer-groups:
UPSTREAM— IPv4 neighbours, activated underaddress-family ipv4 unicast.UPSTREAM6— IPv6 neighbours, activated underaddress-family ipv6 unicastwithnext-hop-self.
no bgp default ipv4-unicast is emitted so a v6 peer is not auto-activated for
IPv4. IPv6 iBGP runs natively over the v6 loopback session — v6 NLRI on a v6
transport — not v6-NLRI-over-a-v4-session.
How subscriber announcement works
IPv4 — host routes, loopback excluded
The prefix-list excludes the loopback and permits only host routes in the subscriber supernets:
ip prefix-list SUBSCRIBER-PREFIXES seq 5 deny 10.255.0.4/32
ip prefix-list SUBSCRIBER-PREFIXES seq 10 permit 100.64.0.0/10 ge 32 le 32
route-map SUB-ROUTES-TO-BGP permit 10
match ip address prefix-list SUBSCRIBER-PREFIXES
Set host_routes_only: false to announce the subscriber_networks at their
natural length instead of per-/32.
IPv6 — aggregate only
IPv6 announces the aggregate, not per-customer prefixes:
ipv6 route 2001:df4:2040:1000::/52 blackhole ! contributor + discard
router bgp 64512
address-family ipv6 unicast
aggregate-address 2001:df4:2040:1000::/52 summary-only
summary-onlysuppresses the per-customer/56//60more-specifics from BGP while they still forward locally.- The
blackholeroute guarantees the aggregate always has a contributor, so it is announced even with zero active subscribers, and unallocated space is discarded rather than looped back to the border.
Per-subscriber IPv6 prefixes are RADIUS-assigned (fail-closed, no local pool).
Monitoring
# IS-IS adjacencies and LSDB (should carry only loopbacks)
sudo vtysh -c "show isis neighbor"
sudo vtysh -c "show isis database detail"
# BGP sessions (v4 and v6 peers)
abng> show bgp summary
sudo vtysh -c "show bgp ipv4 unicast summary"
sudo vtysh -c "show bgp ipv6 unicast summary"
# What we advertise
sudo vtysh -c "show bgp ipv4 unicast neighbors 10.255.0.1 advertised-routes"
sudo vtysh -c "show bgp ipv6 unicast 2001:df4:2040:1000::/52"
Troubleshooting
iBGP neighbour not establishing
- Loopback reachable via the IGP?
sudo vtysh -c "show isis database", thenping <peer-loopback>. update_source: loset on both ends?- v6 peer: is
system.router_id_v6set and the/128in IS-IS? - Firewall permits TCP 179 on the core interface.
IS-IS adjacency not forming
sudo vtysh -c "show isis neighbor".- Both ends single-instance dual-AFI (MikroTik
afi=ip,ipv6; FRR onerouter isis)? network_typeand level agree on both ends of the P2P link.
IPv6 aggregate missing upstream
The more-specifics are suppressed on purpose. Confirm:
announce_subscriber_routes_v6: trueand thesubscriber_networks_v6entry.- The
ipv6 route <net> blackholecontributor is present (show ipv6 route <net>). show bgp ipv6 unicast <net>shows the aggregate originating.
Advanced
BGP communities
Tag announced subscriber routes with a community (applied in both the v4 and v6 route-maps):
routing:
bgp:
community: "64512:100"
Loopback addressing
Infrastructure sits outside the subscriber aggregate. In the reference plan the
loopbacks live in 2001:df4:2040::/64 (BNG ::4, BDR1 ::1) and the BNG↔BDR1
P2P link is a /127 in 2001:df4:2040:1::/64 — kept entirely separate from the
announced 2001:df4:2040:1000::/52 subscriber block.
Next steps
- Routing Configuration — every routing knob
- Routing feature overview — the two-plane design
- VRF Steering — VRF-based traffic steering