policy routing support

Hi,
I’m doing policy routing of two /24 subnets going to isp2 and two /24 going to isp1 throught default gateway. The only problem I experience is isp2 subnets cannot ping to isp1 subnets. They go directly to routing table of isp2 and leaves the route using default gateway. As far as my knowledge says local table gets the highest priority. here is the image :
192.168.53. and 192.168.41 subnets cannot reach 192.168.7 and 192.168.5. I’d made a workaround by marking the packets with !dst to exclude these subnets in destinations. But I dont want to use iptables for that. Someone come forward to assist me where things are going wrong.
pbr.png

You need to create more policy rules, which must be located at the beginning of your policy route ruleset.
For each of your LAN subnets, you need to create a rule which says dst=$Lan_Subnet action=lookup table=main (do not enter anything in src) - otherwise the subnets won’t be able to communicate with each other, as traffic will be looked up in the wrong table (isp2), where there is only a default route towards the ISP, so the traffic will be sent through your default gateway.

i did the same but nothing happened. I’ll do it again and report back(maybe I used src )
thanks

I did it but of no use.

added all the subnets to look for main table
4 subnets of lan and 2 subnets of isp1 and isp2
it resolved the problem