A backup of a configured router loses its BGP, OSPF, SCION, name servers and IPv6 configuration #1279

Closed
opened 2026-11-09 21:43:33 +00:00 by jaylouisw · 0 comments
Owner

Eight layer-3 features are configurable, stored in device.config, and printed nowhere by
show running-config. A backup of a configured router comes back without its routing protocol.

r1(config)#ip name-server 10.0.0.9
r1(config)#scion 1-ff00:0:110
r1(config)#ospf router-id 1.1.1.1
r1(config)#router bgp 65001
r1(config)#neighbor 10.0.0.2 remote-as 65002
r1(config)#interface Gi0
r1(config-if)#ipv6 address 2001:db8:1::1/64
r1(config-if)#ip ospf cost 20
r1(config-if)#ipv6 nd ra enable
r1(config)#end
r1#show running-config
! PacketForge running-config
hostname ASR 1001-X aggregation services router-r1
interface Gi0
exit
...
feature stored in printed
ip name-server <addr> config.dnsServers no
scion <isd-as> config.scionAs no
ospf router-id, ospf area config.ospf no
ip ospf cost|area|passive config.ospf.interfaces[] no
router bgp, bgp router-id, neighbor … remote-as config.bgp no
ipv6 address <p>/<len> config.ip6[iface] no
ipv6 route, ipv6 gateway config.routes6, config.gateway6 no
ipv6 nd ra|suppress-ra|prefix config.ra no

Why the existing test could not see it

test/config-roundtrip.test.js asserts the printed config replays and that nothing configured is missing
from the text. Both are true of a feature nobody configured: the sweep prints each device's config and reads
it back, and a feature absent from the device is trivially consistent. Same class as #1232 (VRRP), but one
level out.

What "done" looks like

  • each of the eight appears in show running-config in the exact spelling the parser accepts back;
  • a router with all eight configured prints a config that replays byte-identically into a fresh device
    of the same model, with zero rejected lines - measured on the ASR 1001-X, the ISR 4331 and the generic
    router;
  • a device that never touched them prints none of them (no invented defaults);
  • the printer emits lines in an order that replays: ospf router-id before the interface blocks whose
    ip ospf … lines require the process to exist;
  • the structural guard: a test declares every key device.config can hold with the pattern the printer
    must produce for it, so a new piece of state that nobody taught the printer fails the suite instead of
    shipping as a silent omission.

Related, one level down: a DHCP pool's leaves (no network, no host <addr>, no excluded-address <one>,
no range, …) are half missing and half silent, and no excluded-address 10.5.0.5 clears the whole list
including 10.5.0.6.

Eight layer-3 features are configurable, stored in `device.config`, and printed nowhere by `show running-config`. A backup of a configured router comes back without its routing protocol. ``` r1(config)#ip name-server 10.0.0.9 r1(config)#scion 1-ff00:0:110 r1(config)#ospf router-id 1.1.1.1 r1(config)#router bgp 65001 r1(config)#neighbor 10.0.0.2 remote-as 65002 r1(config)#interface Gi0 r1(config-if)#ipv6 address 2001:db8:1::1/64 r1(config-if)#ip ospf cost 20 r1(config-if)#ipv6 nd ra enable r1(config)#end r1#show running-config ! PacketForge running-config hostname ASR 1001-X aggregation services router-r1 interface Gi0 exit ... ``` | feature | stored in | printed | |---|---|---| | `ip name-server <addr>` | `config.dnsServers` | **no** | | `scion <isd-as>` | `config.scionAs` | **no** | | `ospf router-id`, `ospf area` | `config.ospf` | **no** | | `ip ospf cost\|area\|passive` | `config.ospf.interfaces[]` | **no** | | `router bgp`, `bgp router-id`, `neighbor … remote-as` | `config.bgp` | **no** | | `ipv6 address <p>/<len>` | `config.ip6[iface]` | **no** | | `ipv6 route`, `ipv6 gateway` | `config.routes6`, `config.gateway6` | **no** | | `ipv6 nd ra\|suppress-ra\|prefix` | `config.ra` | **no** | ## Why the existing test could not see it `test/config-roundtrip.test.js` asserts the printed config replays and that nothing configured is missing from the text. Both are true of a feature nobody configured: the sweep prints each device's config and reads it back, and a feature absent from the device is trivially consistent. Same class as #1232 (VRRP), but one level out. ## What "done" looks like * each of the eight appears in `show running-config` in the exact spelling the parser accepts back; * a router with all eight configured prints a config that replays **byte-identically** into a fresh device of the same model, with zero rejected lines - measured on the ASR 1001-X, the ISR 4331 and the generic router; * a device that never touched them prints none of them (no invented defaults); * the printer emits lines in an order that replays: `ospf router-id` before the interface blocks whose `ip ospf …` lines require the process to exist; * **the structural guard**: a test declares every key `device.config` can hold with the pattern the printer must produce for it, so a new piece of state that nobody taught the printer fails the suite instead of shipping as a silent omission. Related, one level down: a DHCP pool's leaves (`no network`, `no host <addr>`, `no excluded-address <one>`, `no range`, …) are half missing and half silent, and `no excluded-address 10.5.0.5` clears the *whole* list including `10.5.0.6`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jaylouisw/packetforge#1279
No description provided.