Community discussions

MikroTik App
 
javedshotline
newbie
Topic Author
Posts: 26
Joined: Mon Jan 23, 2012 9:09 pm

Unable to access both WAN networks from LAN

Sat Feb 11, 2012 8:37 pm

LAN 192.168.1.0/24
LAN 192.168.2.0/24

WAN1 192.168.10.10/24 DSL Modem1 192.168.10.1
WAN2 192.168.11.11/24 DSL Modem2 192.168.11.1

i am using mangle rule to mark lan traffic so 192.168.1.0/24 goes through 192.168.10.1
and 192.168.2.0/24 goes through 192.168.11.1

I want to access both modems from both subnets of LAN
Now the problem is when i try to access modem1 from 192.168.1.0/24 it works but when i try to access from different subnet 192.168.2.0/24 it is not opening untill i change the gateway for 192.168.2.0/24 to 192.168.10.1

thnx for help :)
 
User avatar
cbrown
Trainer
Trainer
Posts: 1839
Joined: Thu Oct 14, 2010 8:57 pm
Contact:

Unable to access both WAN networks from LAN

Sun Feb 12, 2012 2:18 am

Please provide /ip firewall export /ip address print /ip route print detail /interfaces print detail
 
javedshotline
newbie
Topic Author
Posts: 26
Joined: Mon Jan 23, 2012 9:09 pm

Re: Unable to access both WAN networks from LAN

Sun Feb 12, 2012 6:03 pm

/ip firewall mangle
add action=mark-routing chain=prerouting comment="192.168.1.0/24" \
    disabled=no new-routing-mark=LAN1 passthrough=no \
    src-address=192.168.1.0/24
add action=mark-routing chain=prerouting comment="192.168.2.0/24" \
    disabled=no new-routing-mark=LAN2 passthrough=no \
    src-address=192.168.2.0/24
/ip route
add comment="to WAN1" disabled=no distance=1 \
    dst-address=0.0.0.0/0 gateway=192.168.10.1 routing-mark=LAN1 scope=30 \
    target-scope=10
add comment="to WAN2" disabled=no distance=1 \
    dst-address=0.0.0.0/0 gateway=192.168.11.1 routing-mark=LAN2 scope=30 \
    target-scope=10
add comment="Default Gateway" disabled=no distance=1 \
    dst-address=0.0.0.0/0 gateway=192.168.11.1 scope=30 \
    target-scope=10

Who is online

Users browsing this forum: No registered users and 10 guests