Community discussions

MikroTik App
 
RichardPar
just joined
Topic Author
Posts: 1
Joined: Wed Dec 03, 2014 10:02 pm

Subnet and Routing

Wed Dec 03, 2014 10:12 pm

Hi there,

I am trying the most basic thing on Tik and I am completely lost. I have 2 seperate NET ranges and I am trying to route between them.. its an easy layout to learn how this routing thing works - I am using one RB750.

(Segment A) RB750-PORT1 = 192.168.1.1/24
(Segment B) RB750-PORT2 = 192.168.20.1/254

I have computers attached to each segment (COMP-B) 192.168.20.2 on B and (COMP-A) 192.168.1.2 on A

From COMP-B I can ping 192.168.1.1 (RB) but I cannot ping COMP-A which is attached to the physical port. I

I added a static route 192.168.1.0/24 Gateway 192.168.20.1 but nothing seems to help much in getting data through. I dont have any firewall rules to stop anything.. should there be any to allow?

Regards
Richard
 
error216216
newbie
Posts: 25
Joined: Fri May 23, 2014 2:07 am

Re: Subnet and Routing

Thu Dec 04, 2014 11:47 pm

The static rule is not correct, is says if traffic wants to get to subnet 192.168.1.0/24, send it to ip 192.168.20.1 but this ip is not part of that subnet and being on the same device it clearly does not have another route to use, anyway...

The mikrotik creates the rules for you, you should have dinamic rules that look like this:
dst address: 192.168.1.0/24 gateway: port1 pref source 192.168.1.1
dst address: 192.168.20.0/24 gateway: port2 pref source 192.168.20.1

Now if comp A has ip 192.168.1.2 mask 255.255.255.0 gw 192.168.1.1
and comp B has ip 192.168.20.2 mask 255.255.255.0 gw 192.168.20.1
ping between them should work

If you have another gateway on comp A for example ip 192.168.1.2 mask 255.255.255.0 gw 192.168.1.10
the ping will not work between them and you should add in 192.168.1.10 device a static rute like this:
dst address: 192.168.20.0/24 gw: 192.168.1.2