openvpn server on windows pc that is not the LAN gateway

This forum is for admins who are looking to build or expand their OpenVPN setup.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
jamesk6423
OpenVpn Newbie
Posts: 2
Joined: Thu Feb 09, 2023 5:45 pm

openvpn server on windows pc that is not the LAN gateway

Post by jamesk6423 » Thu Feb 09, 2023 5:53 pm

I'm hoping someone can help me with the routes I need to push for my setup. I have OpenVPN server installed on a windows 10 PC on the local LAN subnet of 192.168.200.0/24. The computer running openvpn server has a LAN ip of 192.168.200.75 the gateway on that LAN is 192.168.200.1. The VPN client subnet is 192.168.222.0/24. I can connect to the openvpn server from the openvpn client app on IOS but I cannot ping any devices on the local LAN subnet of 192.168.200.0/24 from the IOS device. I have setup OpenVPN several times in the past without issue but in those cases, the OpenVPN server resided on a pfsense box that was also the gateway for the local LAN. In this case, I think my problem lies with the OpenVPN server not being the gateway for the local LAN.

I have tried adding the line:

push "route 192.168.200.0 255.255.255.0 192.168.200.1" to the server config file but that did not allow the VPN client to ping or access any devices on the local LAN subnet of 192.168.200.0/24. In this configuration, what routes would I need to push to allow the vpn clients on the subnet 192.168.222.0/24 to access the local LAN subnet of 192.168.200.0/24 when the OpenVPN server is not the local LAN gateway (local LAN gateway is 192.168.200.1)? Thanks for any help you can provide, I've been pulling my hair out with this!

Meserias
OpenVpn Newbie
Posts: 18
Joined: Sun Oct 17, 2021 3:01 pm

Re: openvpn server on windows pc that is not the LAN gateway

Post by Meserias » Fri Feb 10, 2023 11:55 am

make sure you enable forwarding on that Win10 PC !
Via PS you will need to:

Code: Select all

Set-NetIPInterface -Forwarding Enabled

jamesk6423
OpenVpn Newbie
Posts: 2
Joined: Thu Feb 09, 2023 5:45 pm

Re: openvpn server on windows pc that is not the LAN gateway

Post by jamesk6423 » Fri Feb 10, 2023 11:33 pm

That was the issue. Everything is working fine now. Thank you for the info!

Post Reply