Description | This article explains the ADVPN net-device feature and its beaviour. |
Scope | FortiGate v7.0+ |
Solution |
To configure ADVPN in v7.0+, the net-device feature should be disabled on the HUB FortiGate and enabled in all the spoke devices.
This feature is configured under the IPsec VPN phase-1 configuration and helps in creating dynamic tunnel interfaces for the shortcut tunnels. Once a shortcut tunnel is created, a route is installed in the routing table and kernel routing table. This shortcut route is used for routing the traffic over the shortcut tunnel.
config vpn ipsec phase1-interface set net-device <enable/disabled> end
Example(ADVPN with BGP over loopback):
Spoke1 Public IP = 10.9.10.109 Spoke 2 Public IP = 10.9.10.120 HUB Public IP = 10.9.10.51
Src 172.17.1.1 --Spoke2--------------toHub1-Pri------------HUB----------------toHub1-Pri---------------Spoke1---------Dst 172.16.1.1
When the net-device is enabled on the Spoke2 firewall, the following routing information is observed:
Initially, traffic is routed via the HUB FortiGate:
Spoke2 # get router info routing details 172.16.1.1 Routing table for VRF=0
Spoke2 # exec ping 172.16.1.1
Spoke2 # get router info routing details 172.16.1.1
Kernel route with the dynamic tunnel interface:
Spoke2 # get router info kernel | grep 172.16.1.1
'diag ip address list' command can provide additional information in case tunnel IPs are configured.
If the net device needs to be disabled on the spoke firewall, the traffic will still function normally. However, no shortcut route will be installed in the routing table. The kernel routing table will also not have the dynamic tunnel route.
Each dynamic tunnel is assigned a tunnel ID, represented as an IP address, which serves as the gateway in the route entry for that tunnel. This tunnel ID is used to identify the correct shortcut route. However, the IPsec tunnel monitor will still display the shortcut route, but it will not be installed in the routing table.
Note: SD-WAN ADVPN routing may not work correctly on the spoke where the net-device is disabled because routing information serves as one of the inputs for SD-WAN intelligence. Since dynamic shortcut interfaces are not added to the routing table, this can cause issues in selecting the outgoing interface for SD-WAN.
Tunnel list output after the shortcut is created when the net-device is disabled:
Spoke2 # di vpn tunnel list
Routing table:
Spoke2 # get router info routing-table de 172.16.1.1 Routing table for VRF=0
Kernel route after disabling the net-device in the spoke firewall:
Spoke2 # get router info kernel | grep 172.16.1.1
In the above route, although the outgoing interface toHub1-Pri belongs to the HUB firewall, the tunnel ID can identify the correct shortcut tunnel.
Related articles: Technical Tip: 'set net-device' new route-based IPsec logic Troubleshooting Tip: Error message 'unregister_netdevice: waiting for Dialup_VPN_Name to become free...Technical Tip: Unable to add IPsec Dial-up interface in an SD-WAN Zone Technical Tip: Reason behind why the net-device 'enable' is not supported on the HUB with SD-WAN |