Created on
05-28-2025
11:49 PM
Edited on
08-25-2025
06:52 AM
By
Anthony_E
Description | This article describes how FortiGate selects routes, exploring the hierarchy of routing components: policy-based routes (PBR), SD-WAN rules, and the Forwarding Information Base (FIB). It will also provide key troubleshooting commands to help diagnose and resolve routing issues effectively. |
Scope | FortiGate. |
Solution |
The Route Selection Process in FortiGate:
Configuration Example:
config router policy
This PBR routes traffic from 192.168.1.0/24 to 10.0.0.0/24 via wan2, regardless of the routing table. If no PBR matches, FortiGate moves to SD-WAN rules (if applicable).
2. Route for predefined internet services (ISDB): The Internet Service Database (ISDB) is an extensive and publicly accessible database that categorizes IP addresses based on various criteria, including IP address ranges, ownership information, associated service port numbers, and an evaluation of IP security credibility. This valuable data is sourced from the FortiGuard service system.
To establish a static route for specific internet services categorized under the ISDB, refer to the detailed guide provided in this article: Technical Tip: Creating a static route for Predefined Internet Services (ISDB).
Creating static routes for predetermined services enhances network management by allowing for more granular control over how traffic is directed based on service type.
In this context, ISDB operates as a policy route, which means that it follows the same set of rules and configurations typically applied to policy-based routing. This functionality allows network administrators to apply specific routing policies that optimize traffic flow based on service requirements.
To verify and audit the ISDB route configurations within the network environment, execute the command 'diagnose firewall proute list' in the device's command line interface.
3. SD-WAN Rules:
Example: A rule might direct VoIP traffic over the link with the lowest latency to ensure call quality. If no SD-WAN rule applies, FortiGate consults the FIB.
4. Forwarding Information Base (FIB):
Example: If two static routes to 10.0.0.0/24 exist—one via wan1 (AD 10, priority 5) and one via wan2 (AD 10, priority 10), FortiGate chooses wan1 due to its lower priority.
Troubleshooting Route Prioritization: When routing issues arise, FortiGate’s CLI provides powerful commands to diagnose and resolve problems. Below are key commands and their uses.
get router info routing-table all <----- Displays the entire routing table, including static, dynamic, and connected routes.
diagnose firewall proute list <----- Lists all configured PBRs, showing their IDs, conditions, and actions.
get router info routing-table database
Shows all known routes, including those not selected as the best path.
get router info routing-table details <destination IP>
Provides in-depth information about how a specific destination is routed.
diagnose sys sdwan service
Displays SD-WAN rule details and their current status.
get router info bgp neighbors
To find out the number of prefixes that have been accepted by a particular BGP neighbor.
Scenario 1: Using PBR to Direct Specific Traffic.
Command:
config router policy
diagnose system sdwan service
get router info routing-table details <destination IP>
Troubleshooting: The following commands can be used to collect debug log to find out information matching with routes and Firewall policy
diagnose debug reset diagnose debug flow trace stop diagnose debug flow filter clear diagnose debug flow filter addr <Source IP/Destination IP > diagnose debug flow filter port <Port Number> diagnose debug flow show function-name enable diagnose debug console timestamp enable diagnose debug flow trace start 1000 diagnose debug enable
To stop the debug:
diagnose debug disable
Related articles: Technical Tip: Routing in FortiGate (route-lookup-process) Technical Tip: How to Perform Routing Lookup from GUI and CLI |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.