Chapter 2 Advanced Routing for FortiOS 5.0 : Advanced Static Routing : Advanced static example: ECMP failover and load balancing : Configuring spillover or usage-based ECMP
  
Configuring spillover or usage-based ECMP
Spill-over or usage-based ECMP routes new sessions to interfaces that have not reached a configured bandwidth limit (called the Spillover Threshold or a route-spillover threshold). To configure spill-over or usage-based ECMP routing, you enable spill-over ECMP, add ECMP routes, and add a Spillover Threshold to the interfaces used by the ECMP routes. Set the Spillover Thresholds to limit the amount of bandwidth processed by each interface. The range is 0 to 2 097 000 Kbps. The threshold counts only outgoing traffic.
With spill-over ECMP routing configured, the FortiGate unit routes new sessions to an interface used by an ECMP route until that interface reaches its Spillover Threshold. Then, when the threshold of that interface is reached, new sessions are routed to one of the other interfaces used by the ECMP routes.
To add Spillover Thresholds to interfaces - web‑based manager
Use the following steps to enable usage based ECMP routing, add Spillover Thresholds to FortiGate interfaces port3 and port4, and then to configure EMCP routes with device set to port3 and port4.
1. Go to Router > Static > Settings.
2. Set ECMP Load Balance Method to Spillover.
3. Go to Router > Static > Static Routes.
4. Add ECMP routes for port3 and port4.
 
Destination IP/Mask
192.168.20.0/24
Device
port3
Gateway
172.20.130.3
Advanced
 
 
Distance
10
 
Destination IP/Mask
192.168.20.0/24
Device
port4
Gateway
172.20.140.4
Advanced
 
 
Distance
10
5. Go to System > Network > Settings.
6. Edit port3 and port4 and add the following spillover-thresholds:
 
Interface
port3
Spillover Threshold
100
 
Interface
port4
Spillover Threshold
200
To add Spillover Thresholds to interfaces - CLI
config system settings
set v4-ecmp-mode usage-based
end
config router static
edit 1
set device port3
set dst 192.168.20.0 255.255.255.0
set gateway 172.20.130.3
next
edit 2
set device port4
set dst 192.168.20.0 255.255.255.0
set gateway 172.20.140.4
end
config system interface
edit port3
set spillover-threshold 100
next
edit port4
set spillover-threshold 200
end