This is a work in progress, I will be... Full Story
By Manny Fernandez
May 20, 2019
Route-Map on Fortigate
Often times you need to create a route map on a device to control what routes the device is advertising. Here is my scenario.
Branch location has a ‘Data‘ VLAN (ID100 172.22.100.0/24) and a ‘Voice‘ VLAN (ID101 172.22.101.0/24). I am using OSPF to route across to the main location and all other branches.
Creating an ‘access-list’
The access list will be used to match something. In my example below, it is the two network 172.22.100.0/24 and 172.22.101.0/24
config router access-list edit "allowed-connected-routes" config rule edit 1 set prefix 172.22.100.0 255.255.255.0 set exact-match enable next edit 2 set prefix 172.22.101.0 255.255.255.0 set exact-match enable next end
As you can see above, we create a ‘rule‘. By issuing an ‘edit 3‘, ‘edit 4‘ etc, you can add additional networks.
Then once you have the access list, we will create the route-map
Creating the Route Map
config router route-map edit "connected-to-ospf" config rule edit 1 set match-ip-address "allowed-connected-routes" next end
Then, we will configure the OSPF
Configuring OSPF
config router ospf set router-id 172.30.255.1 config area edit 0.0.0.0 next end config ospf-interface edit "LAN1" set interface "lan1" set dead-interval 40 set hello-interval 10 next end config network edit 2 set prefix 172.30.255.1 255.255.255.0 next end set passive-interface "ssl.root" "wan" "colo-vpn" "lan2" "lan3" "lan4" config redistribute "connected" set status enable set routemap "connected-to-ospf" end config redistribute "static" end config redistribute "rip" end config redistribute "bgp" end config redistribute "isis" end end
As you can see, the focus should be on the ‘redistribute connected‘ section. This method can be used for any of the dynamic routing protocols.
Hope this helps.
Recent posts
-
-
I have been playing with the free version of... Full Story
-
In my day job, I am on a lot... Full Story