Dynamic definitions of SD-WAN routes alleviate administrators from needing to know the destination of the traffic that is being load balanced, which, in an environment where routes are constantly added and removed, required a significant amount of administrative overhead.
The FortiGate can be configured to apply a route map to a BGP neighbor, and tag the routes that are learned from that neighbor with the
set-route-tag command. After those routes are assigned a tag ID in the route map, the ID can be referenced in the SD-WAN rule.
To define the route map to apply to the BGP neighbor:
config router route-map edit "map-comm1" config rule edit 1 set match-origin igp set set-route-tag 12 next edit 2 set match-ip-address "pf-all-in" set set-route-tag 11 next end next end
To apply the route map to the BGP neighbor:
config router bgp config neighbor edit "10.254.0.1" set route-map-in "map-comm1" next end end
To reference tagged routes in an SD-WAN rule:
config system virtual-wan-link config service edit 1 set mode priority set dst-tag 11 set health-check "datacenter1" set priority-members 1 2 next end end