Connect server to home network and give it a unique "ID".

TheRavenBlue

Prominent
Apr 28, 2017
5
0
510
I have a server that I connect to my home network using PPTP VPN the problem I have is that I can't open port to the server on my router.
I'll explain: The server gets the IP: 192.168.1.200 and my Raspberry Pi that has the PPTP server has the IP 192.168.1.87. When I go onto my router it looks like this: https://gyazo.com/63b08657ac72850592dcfdc2c7dd8566
As you can see the server IP is under the same name as the Raspberry I can't open the port to server when I type in the IP address it automatically changes it to 87 instead of 200.
I think it does that becuse those 2 have the same MAC address (correct me if I'm wrong)
What can I do to open the port to the server?
Shall I try some other VPN server, I tried to setup a OpenVPN server on Windows but I could not get it to work.
 
Solution

You don't open ports to a network. On a router, you port-forward ports toward a specific IP address.

Once you have VPN server behind the router, the only port you should have open (and it seems you did, once you are able to connect to tour VPN server presumably running on RPi) is the port needed for VPN to work. Once you're connected to the VPN server, all traffic flows thru that server. No more ports involved there.

Now, you still did not answer the specific questions I've asked - why you want to connect your office PC to your home network?

And last but not least - I hope you have your office' admin knows what you're doing.
In any single (home) network, every device should have unique MAC address (which is more or less hard-coded into it by the manufacturer), and unique IP address (which is under your or DHCP server control).

Port-forwarding works on port numbers. If you want to be able to connect externally, you should assign different ports (on your external address) to different devices.

Finally - what's VPN server (or client) doing in that game? Where does it resides? Who is connecting to it (if server)?
 

TheRavenBlue

Prominent
Apr 28, 2017
5
0
510


Server connects to Pi which is running a PPTP server.
The thing is I can assign a port to the connected server that ends in 200, when I do that the router automatically changes from 192.168.1.200 to 192.168.1.89 as those 2 IP adresses have the same MAC Addres on my router.

I have a dedicated server that is located on my job but it is behind a firewall and I cant open ports to it that is why I have the server connected to my home network through VPN so I can open ports to it.

 
Your "router" is correct - it sees requests from .200 coming from your RPi, so it thinks (correctly) that RPi got two IP addresses. It should be up to RPi to forward all packets for .200 thru the VPN link.

But I suppose your network topology is wrong. You should either move the VPN server to your router, or create a totally different network for VPN traffic, eg 10.0.0.x. You'll still have troubles though as your router (or your PC) won't know anymore what to do with traffic fto 10.x.y.z (unless you install VPN cients on them as well).
 

TheRavenBlue

Prominent
Apr 28, 2017
5
0
510


My router does not support VPN server unfortunately, but do you have any other suggestions on how I may fix this. Maybe OpenVPN would work?

 
You missed an important piece of info - what is your final goal? Access your work PC from a home PC? From several PCs at home? Access several home PCs from work PC?

I am not an expert in OpenVPN, so I don't know whether it will help if you (manage to) load it onto RPi.
 

TheRavenBlue

Prominent
Apr 28, 2017
5
0
510


I want to open ports to the server that is connected to my private network.

 

You don't open ports to a network. On a router, you port-forward ports toward a specific IP address.

Once you have VPN server behind the router, the only port you should have open (and it seems you did, once you are able to connect to tour VPN server presumably running on RPi) is the port needed for VPN to work. Once you're connected to the VPN server, all traffic flows thru that server. No more ports involved there.

Now, you still did not answer the specific questions I've asked - why you want to connect your office PC to your home network?

And last but not least - I hope you have your office' admin knows what you're doing.
 
Solution

TRENDING THREADS