Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a server running openvpn for outgoing connections. However, once I start openvpn, I lose SSH, HTTP access to the server's IP. This is expected I guess, but is there a way to circumvent the VPN connection when connecting to these ports?

share|improve this question

1 Answer 1

Try setting a static route to the Server's address to go through eth0, wlan0, etc. This should bypass the tunnel interface explicitly. If you need to do this on a port level, try IPTABLES

Linux

inet_route [-vF] add {-host|-net} Target[/prefix] [gw Gw] [metric M]
                          [netmask N] [mss Mss] [window W] [irtt I]
                          [mod] [dyn] [reinstate] [[dev] If]

Windows

route ADD 157.0.0.0 MASK 255.0.0.0  157.55.80.1 METRIC 3 IF 2
       destination^      ^mask      ^gateway     metric^    ^
                                                   Interface^
If IF is not given, it tries to find the best interface for a given
gateway.
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.