Community discussions

MikroTik App
 
zorans
just joined
Topic Author
Posts: 18
Joined: Tue Mar 23, 2010 6:12 pm

Mikrotik PPTP connecting remote client to local LAN's

Mon Oct 24, 2011 9:25 pm

I have already setup PPTP server and I can ping all computers on local lan.

What I can not do is ping computers on other lan's connected to Mikrotik router as in example:

LAN1: 192.168.3.0/24
LAN2: 172.10.130.0/24
LAN3: 172.50.120.0/24
WAN:

Where LAN2 is local lan where pptp client is connected.

Is it possible to access other lan networks through pptp tunel?

P.S. Lans are already routed. I can ping other lan's when "Use default gateway on remote network" is checked on client but I don't want to do that for obvious reasons. I am connecting from home laptop.
RouterOS 4.6
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Mon Oct 24, 2011 9:53 pm

Hi,
It may depends on your routes or firewall rules. did you try traceroute?
Just give more information like Network diagram, your routes, IP addresses,firewall rules, Interface detail, PPTP server and clients profile.
 
zorans
just joined
Topic Author
Posts: 18
Joined: Tue Mar 23, 2010 6:12 pm

Re: Mikrotik PPTP connecting remote client to local LAN's

Mon Oct 24, 2011 10:13 pm

Hi,
It may depends on your routes or firewall rules. did you try traceroute?
Just give more information like Network diagram, your routes, IP addresses,firewall rules, Interface detail, PPTP server and clients profile.

I just tried to connect from Windows XP machine and it works. Do you have any idea why it does not work from Windows 7 64-bit?

Tracert goes to my home adsl gateway. There is no route for other lan's in "route print". There is route for LAN2.
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Mon Oct 24, 2011 10:25 pm

I still don't know as you know about your network.
You say there is not any route for other LANs?
tell me where is your PC (on which router Interface)? and where do you want to access(which Interface)?
do you have any route for this action?
all direct connected interfaces should have ADC route (Active, Dynamic- Connected) if you add correct IP address to that.
 
zorans
just joined
Topic Author
Posts: 18
Joined: Tue Mar 23, 2010 6:12 pm

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 12:07 am

My laptop is at my home. Mikrotik pptp server is at my workplace.
When I connect to pptp server there is dynamic interface created of type PPTP server.
networks connected to Mikrotik ([pptp server) router at workplace:
LAN1: 192.168.3.0/24
LAN2: 172.10.130.0/24
LAN3: 172.50.120.0/24

I have all the routes for all interfaces and everything is working fine between lan1, lan2 and lan3 locally.

excerpt from "route print" on windows 7 laptop (pptp client connected)
0.0.0.0 0.0.0.0 172.39.150.1 172.39.150.100 20
172.39.150.0 255.255.255.0 On-link 172.39.150.100 276
172.10.0.0 255.255.0.0 172.10.130.1 172.10.130.93 21
172.10.130.93 255.255.255.255 On-link 172.20.130.93 276

172.39.150.0 is my home network
172.10.130.0 is LAN2 at workplace (network that pptp client is connected to)
172.10.130.93 is pptp client

tracert 192.168.3.50 goes to 172.39.150.1 instead of going through pptp tunnel
tracert 172.50.120.50 goes to 172.39.150.1 instead of going through pptp tunnel
tracert 172.10.130.50 goes to 172.10.130.1 through pptp tunnel as it is supposed to

Forget that part about Windows XP, I forgot to uncheck "Use default gateway ..." on Windows XP machine.

I tried to disable all firewall rules (no change).

PPTP server and clients profile are setup as in http://wiki.mikrotik.com/wiki/Manual:Interface/PPTP under Application Examples - Connecting Remote Client
You do not have the required permissions to view the files attached to this post.
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 7:59 am

Why did you use 172.10.x.y ,172.50.x.y and 172.39.x.y ? They aren't Private IP addresses. See http://en.wikipedia.org/wiki/Private_network
How do you say there is no problem with LANs while there is no route for them in MK route list?
You set similar IP Range to Your PPTP Server and LAN2, that's wrong!!!

As I said before
all direct connected interfaces should have ADC route (Active, Dynamic- Connected) if you add correct IP address to that
Like This:
IP.PNG
Route.PNG
You do not have the required permissions to view the files attached to this post.
 
zorans
just joined
Topic Author
Posts: 18
Joined: Tue Mar 23, 2010 6:12 pm

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 11:07 am

Ok, everything is fine with routes. Subnets given in previous post are just examples (badly chosen ones I admit).

Just imagine they are:

LAN1: 192.168.3.0/24
LAN2: 192.168.4.0/24
LAN3: 192.168.5.0/24

That is not the point. Everything is routed and working fine.

Point is in Mikrotik PPTP server. Is it possible to push routes to client?
Only route that is set at client is LAN2
Did you try to connect to multiple lans through pptp tunnel?

LAN1 and LAN3 are not accessible.

What do you mean by:
You set similar IP Range to Your PPTP Server and LAN2, that's wrong!!!
Address given on diagram is local address ie. LAN2 gateway that client points to through pptp tunnel (as in documentation)
PPTP server has public IP
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 11:39 am

here is my pc route print before connect to my MK via PPTP:
before PPTP.png
And this is after connecting :
after PPTP.PNG
You will see I have two default Gateway, but 192.168.100. 2 has lower metric
and I'm able to reach all networks in there.
You do not have the required permissions to view the files attached to this post.
 
zorans
just joined
Topic Author
Posts: 18
Joined: Tue Mar 23, 2010 6:12 pm

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 1:05 pm

Thanks, forgive me if I am reading this incorrectly your
Home network is 192.168.1.0/24 and network you are connected to is 192.168.100.0/24

default route is pointing to remote gateway 192.168.100. 2

if you do tracert www.google.com it will go through remote Mikrotik router


I am trying to avoid this situation because I don't want clients to access Internet through Mikrotik router.


My second question is what happens when you disable "Use default gateway on remote network" in pptp connection properties?

Can you ping other networks on Mikrotik router in that case?
You do not have the required permissions to view the files attached to this post.
Last edited by zorans on Tue Oct 25, 2011 4:21 pm, edited 1 time in total.
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 1:36 pm

I am trying to avoid this situation because I don't want clients to access Internet through Mikrotik router.
yes It goes through Mikrotik Router. for avoiding this, you can remove any NAT rule (which action is "masquerade" your PPTP client IP addresses)
My second question is what happens when you disable "Use default gateway on remote network" in pptp connection properties?

Can you ping other networks on Mikrotik router in that case?
Absolutely Not. I have to add static route for those remote network in CMD.
Point is in Mikrotik PPTP server. Is it possible to push routes to client?
I don't hear anything about this but it's so nice for new research. I will try to find a solution
What do you mean by:
You set similar IP Range to Your PPTP Server and LAN2, that's wrong!!!
Address given on diagram is local address ie. LAN2 gateway that client points to through pptp tunnel (as in documentation)
PPTP server has public IP
Nothing. I think You want to have different network. that's OK.
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 1:53 pm

I have searched for this http://forum.mikrotik.com/viewtopic.php?f=8&t=10405
In there Dear Normis says "There is no way how to send a route through the PPP itself. All those DHCP options are not being sent over the PPP itself. "
I will try to find other solution. :D
 
User avatar
normis
MikroTik Support
MikroTik Support
Posts: 26381
Joined: Fri May 28, 2004 11:04 am
Location: Riga, Latvia

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 1:54 pm

I have searched for this http://forum.mikrotik.com/viewtopic.php?f=8&t=10405
In there Dear Normis says "There is no way how to send a route through the PPP itself. All those DHCP options are not being sent over the PPP itself. "
I will try to find other solution. :D
just notice that this topic is from five years ago
 
User avatar
sadeghrafie
Long time Member
Long time Member
Posts: 514
Joined: Sat Nov 14, 2009 11:28 am
Location: Bushehr, IRAN

Re: Mikrotik PPTP connecting remote client to local LAN's

Tue Oct 25, 2011 2:13 pm

So, Any helpful news?
Can we solve this problem(send certain routes to PPTP Clients) with current tools?

Who is online

Users browsing this forum: Amaan, baragoon, pav5, shahzaddj1 and 172 guests