Community discussions

MikroTik App
 
pastik
just joined
Topic Author
Posts: 12
Joined: Thu Nov 09, 2006 8:00 am

Routing without NAT between two mikrotik

Fri Nov 10, 2006 7:41 pm

Hi all,
I have this problem ... :(

I have Notebook, Mikrotik1 a Mikrotik2:

Notebook = 192.168.100.90
Mikrotik1 = wlan1:192.168.100.1, eth1: 192.168.0.1
Mikrotik2 = eth1:192.168.0.2

Notebook is connected by wifi to Mikrotik1 to wlan1, on mikrotik1 I have static routes between wlan1 a eth1, so I can ping from my notebook everything on Mikrotik1, but I can't ping Mikrotik2 , which is connected with LAN cable to Mikrotik2. How can I set-up the routes to ping Mikrotik2 from my notebook ? I don't want to use any NAT or bridge, just only routes ... Thank you for your time to reply.
 
User avatar
mipland
Member Candidate
Member Candidate
Posts: 210
Joined: Thu Sep 14, 2006 4:02 am

Fri Nov 10, 2006 8:09 pm

Have you set on your laptop 192.168.100.1 as the default gateway?
Have you set on your Mikrotik2 192.168.0.1 as the default gateway (or as a static rule)?
 
pastik
just joined
Topic Author
Posts: 12
Joined: Thu Nov 09, 2006 8:00 am

Fri Nov 10, 2006 8:21 pm

Yes of course, I've set default gateways on my notebook and MK1 nad MK2
 
User avatar
mipland
Member Candidate
Member Candidate
Posts: 210
Joined: Thu Sep 14, 2006 4:02 am

Fri Nov 10, 2006 8:28 pm

Have you set the ip-forwarding on Mikrotik1?
I don't know how to set it on RouterOS, I've never used it.
I say it by network-logic.
 
csickles
Forum Guru
Forum Guru
Posts: 1255
Joined: Fri May 28, 2004 8:46 pm
Location: Phoenix, AZ
Contact:

Fri Nov 10, 2006 10:02 pm

I think I see it..

MikroTik1 knows how to get to MikroTik2 via its default gateway. (and out via MikroTik2's gateway.
MikroTik1 and two can ping each other because they are linked by their common ethernet leg.
Here is the issue..
MikroTik2 does NOT know obout the 192.168.100/24 network.
Add a static route on MikroTik2 for 192.168.100.0/24 with a gateway 192.168.0.1. The router will "pick" the correct interface (wlan1).
Baisickly, the routers know how to send packets forward in your network (twards the gateway), but MikroTik2doesnt know how to get packets back to the far end of MikroTik1

(I have done this with a 10X network.. I have NOT tried this with a 192X)

(I also cant remember if any firewall rules are nessisary on MikroTik1 IE: all traffic from 102.168.0/24 to 192.168.100.0 accept. due to the fact you are crossing the firewall "inbound" with a non routable IP range)

Note: if MikroTik1 was running as a masquerade, for the 192.168.100.XXX network, this would not be needed.

Note2: Routing discovery protocols IR RIP,OSPF etc would also help here.

Craig
"Things that make you go Hmmmmm...."
 
User avatar
mipland
Member Candidate
Member Candidate
Posts: 210
Joined: Thu Sep 14, 2006 4:02 am

Fri Nov 10, 2006 10:13 pm

I already wrote:
Have you set on your Mikrotik2 192.168.0.1 as the default gateway (or as a static rule)?
and pastik answer:
Yes of course
So, if the gateway are correctly setted (or static roule correctly implemented), there shouldn't be any problem, but I suspect that pastik hasn't setted up properly his Mikrotik (or laptop).
Here some hints:

Notebook
IP: 192.168.100.90
Netmask: 255.255.255.0
Default Gateway: 192.168.100.1

Mikrotik 1 - wlan1
IP: 192.168.100.1
Netmask: 255.255.255.0
Default Gateway: 0.0.0.0

Mikrotik 1 - eth1
IP: 192.168.0.1
Netmask: 255.255.255.0
Default Gateway: 0.0.0.0

Mikrotik 2
IP: 192.168.0.2
Netmask: 255.255.255.0
Default Gateway: 192.168.0.1

Or set a static roule on Mikrotik2, such as: net 192.168.100.0/24, gw 192.168.0.1, but it's the same thing of setting a 192.168.0.1 on it's default gateway.
I have done this with a 10X network.. I have NOT tried this with a 192X
Yes, no logical difference between 10.x and 192.x (or 172.x). :wink:
 
pastik
just joined
Topic Author
Posts: 12
Joined: Thu Nov 09, 2006 8:00 am

Fri Nov 10, 2006 10:39 pm

Thanks for your time, but I think I've already done it. It doesn't work. The setting of my notebook is ok, but how to set-up routes between MK1 and MK2 ... there will be a problem although you can ping each other mikrotik directly, but from notebook I have no chance to ping MK2 ... :(
 
User avatar
mipland
Member Candidate
Member Candidate
Posts: 210
Joined: Thu Sep 14, 2006 4:02 am

Fri Nov 10, 2006 10:52 pm

Ok, so, as csickles suggest, check your firewall rules.
 
csickles
Forum Guru
Forum Guru
Posts: 1255
Joined: Fri May 28, 2004 8:46 pm
Location: Phoenix, AZ
Contact:

Fri Nov 10, 2006 11:04 pm

Here is the issue..
MikroTik2 does NOT know obout the 192.168.100/24 network.

Add a static route on MikroTik2 for 192.168.100.0/24 with a gateway 192.168.0.1. The router will "pick" the correct interface (wlan1).

Baisickly, the routers know how to send packets forward in your network (twards the gateway), but MikroTik2doesnt know how to get packets back to the far end of MikroTik1
 
User avatar
mipland
Member Candidate
Member Candidate
Posts: 210
Joined: Thu Sep 14, 2006 4:02 am

Fri Nov 10, 2006 11:07 pm

Baisickly, the routers know how to send packets forward in your network (twards the gateway), but MikroTik2doesnt know how to get packets back to the far end of MikroTik1
Sure, and the default gateway on Mikrotik2 is the way (or a static rule).
 
csickles
Forum Guru
Forum Guru
Posts: 1255
Joined: Fri May 28, 2004 8:46 pm
Location: Phoenix, AZ
Contact:

Fri Nov 10, 2006 11:16 pm

Yes the gateway setting shows MikroTik1 the way out via MikroTik2, but it does nothing to inform MikroTik2 that it (MikroTik1) "hosts" the 192.168.0.X network.

MikroTik2 will recieve a packet from the "100" network, try to look it up in its route table, find no entries and forward it out its default gateway which is out the wrong intrerface.

You need some wat to tell MikroTik2 where the 100 network is.
"Gateway" or "default routes baisickly do the folowing: " I have a packet and I don't know where to send it, OK, shove it out here and let the up stream router figure it out.." Only you need the packet to go "down stream".

You need a static route on MikroTik2 for the 100 net with MikroTik 1 as its' gateway. (or enable a routing protocol between the routers. That will do the same thing but with more work for such a simple net.)

Craig

Who is online

Users browsing this forum: gogodzilla and 7 guests