Dear OpenVPN Community,
I am new to OpenVPN and spent the last two hours researching. I need some advice. Also, I plan to use the service provider SwitchVPN.
Basically, I want to use one dedicated PC running W7 x64 (lets call it PC1) at home that will strictly use OpenVPN. The rest of the computers on the home LAN will use my normal home IP. I know all internet connections on PC1 will run through the SwitchVPN server. However, is it possible for PC1 to access a few shared folders on my fileserver (running Server 2008 R2) which is also on the LAN at home, but WITHOUT having to install VPN/OpenVPN on the fileserver? I am hoping there is a solution besides using a Virtual Machine.
Appreciate any feedback,
Thank You!
OpenVPN - Access Non-OpenVPN PC's on LAN?
Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech
-
- OpenVpn Newbie
- Posts: 3
- Joined: Mon Mar 21, 2011 5:16 am
- janjust
- Forum Team
- Posts: 2703
- Joined: Fri Aug 20, 2010 2:57 pm
- Location: Amsterdam
- Contact:
Re: OpenVPN - Access Non-OpenVPN PC's on LAN?
what does the SwitchVPN service do to the routing tables of PC1?
If PC1 and your fileserver are on the same LAN then it's definitely possible to access shares on it, even if PC1 is connected to a VPN server. You'd need to add a route to the client config similar to
('net_gateway' is a keyword) to ensure that all traffic to the machines on your home LAN are NOT redirected via the tunnel.
If PC1 and the fileserver are on different LANs in the same home then you'll have to explain more about your home network setup
If PC1 and your fileserver are on the same LAN then it's definitely possible to access shares on it, even if PC1 is connected to a VPN server. You'd need to add a route to the client config similar to
Code: Select all
route <home-LAN-IP-range> 255.255.255.0 net_gateway
If PC1 and the fileserver are on different LANs in the same home then you'll have to explain more about your home network setup

-
- OpenVpn Newbie
- Posts: 3
- Joined: Mon Mar 21, 2011 5:16 am
Re: OpenVPN - Access Non-OpenVPN PC's on LAN?
Dear janjust,
Thank you for the quick reply. PC1 and the Fileserver are on the same LAN, in fact on the same Gigabit switch. Adding route looks to easy enough! Now, if my OpenVPN tunnel disconnects, will PC1 start using internet of home IP or simply not work until OpenVPN starts up again? I want PC1 to ONLY use OpenVPN for internet, since the point of VPN for me is to mask my home IP.
How do I find out the answer to "What does the SwitchVPN service do to the routing tables of PC1?" I havn't signed up with SwitchVPN yet, wanted to make sure there was a solution before I signed up. :c)
Thanks so much for your support!
Thank you for the quick reply. PC1 and the Fileserver are on the same LAN, in fact on the same Gigabit switch. Adding route looks to easy enough! Now, if my OpenVPN tunnel disconnects, will PC1 start using internet of home IP or simply not work until OpenVPN starts up again? I want PC1 to ONLY use OpenVPN for internet, since the point of VPN for me is to mask my home IP.
How do I find out the answer to "What does the SwitchVPN service do to the routing tables of PC1?" I havn't signed up with SwitchVPN yet, wanted to make sure there was a solution before I signed up. :c)
Thanks so much for your support!
- janjust
- Forum Team
- Posts: 2703
- Joined: Fri Aug 20, 2010 2:57 pm
- Location: Amsterdam
- Contact:
Re: OpenVPN - Access Non-OpenVPN PC's on LAN?
that depends on how you set up PC1 - make sure it does not have a default route out to the internet, but that it can only reach the SwitchVPN server machine (or machines). If your home router is capable of performing filtering you could also program it there , i.e. block all traffic from PC1 that is NOT going to any of the SwitchVPN servers - on the router it would be slightly easier to do , as you can specify stuff like "block all traffic for PC1 except UDP or TCP traffic to port 1194" (or whatever port SwitchVPN is running on).Now, if my OpenVPN tunnel disconnects, will PC1 start using internet of home IP or simply not work until OpenVPN starts up again?
When OpenVPN stops it will try to restore the routing table as found when it started - so if your routing table was correct before starting then it should be correct after OpenVPN stops.
-
- OpenVpn Newbie
- Posts: 3
- Joined: Mon Mar 21, 2011 5:16 am
Re: OpenVPN - Access Non-OpenVPN PC's on LAN?
Great, I will try to do it through the router. Hopefully it won't block network shares or remote desktop through the LAN. :c)
Thanks for all your priceless knowledge!
Thanks for all your priceless knowledge!