Problem
When a Junos then block in an import policy contains next-hop self, the device does not rewrite the route's next-hop. Batfish predicts the next-hop is set to the local interface IP, producing a mismatch.
Technical Details
next-hop self is documented to apply on egress (export to peer). On import, the action is retained in the post-commit config but the route's next-hop in the RIB remains the sender's interface IP.
Observed:
- Source action:
then next-hop self (in an import policy term).
- Device
show route: next-hop = sender-side interface IP (e.g., 10.0.12.0).
- Batfish prediction: next-hop = local-side interface IP (e.g., 10.0.12.1).
Observed In
junos_then_action_conflicts, prefixes 10.50.32-35 (AIGP-ORIGINATE terms — these include next-hop self to satisfy Junos's commit-time constraint that AIGP-originate requires next-hop in the same then block).
Problem
When a Junos
thenblock in an import policy containsnext-hop self, the device does not rewrite the route's next-hop. Batfish predicts the next-hop is set to the local interface IP, producing a mismatch.Technical Details
next-hop selfis documented to apply on egress (export to peer). On import, the action is retained in the post-commit config but the route's next-hop in the RIB remains the sender's interface IP.Observed:
then next-hop self(in an import policy term).show route: next-hop = sender-side interface IP (e.g., 10.0.12.0).Observed In
junos_then_action_conflicts, prefixes 10.50.32-35 (AIGP-ORIGINATE terms — these include
next-hop selfto satisfy Junos's commit-time constraint that AIGP-originate requires next-hop in the samethenblock).