LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-30-2014, 07:32 AM   #1
stx
LQ Newbie
 
Registered: Nov 2013
Posts: 11

Rep: Reputation: Disabled
Ubuntu Server: connect to VPN client and only affect wget


Hello,

sorry the headline is not very meaningful.

I run an Ubuntu server with apache and I host private php projects on this web server.

I would like to download some files from another network, where I have to be connected via VPN. These files are protected and should not be available for the whole web, thus I can only access them via VPN. Once connected I can download them easily, e.g. with wget.
No problem, I installed an openvpn client on the server and connected, running like a charm. My problem is: the whole traffic is now "redirected" to the other network, so the web server does not work any more with my IP address.

Is it possible that only wget traffic is being downloaded via VPN?

The only thing I could find was http://www.my-pizza.at/blog/2013/10/...se-vpn-tunnel/

But he is having problems realizing his purposes.

Thanks in advance!


stx
 
Old 08-30-2014, 08:03 AM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,140

Rep: Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263
Setting up the VPN changed your default gateway. Either the startup script changed it or a new default gateway was pushed by the server you connected to. Change it back to your regular interface and add a route for the specific IP that should go through the VPN.
 
Old 09-01-2014, 06:08 AM   #3
Rose Ab
LQ Newbie
 
Registered: Sep 2014
Posts: 2

Rep: Reputation: Disabled
whenever OpenVPN makes its connection, it become the default gateway for all your outbound connections. This becomes a problem when you need to reach the machine from outside of you networks, as any responses sent by your server will ultimately end up going across the VPN as its gateway.
Luckily, Linux is pretty powerful when it comes to networking! We can setup our own routes, and give it rules to follow.

The following guide might help you to solve the issue:
http://lartc.org/howto/lartc.rpdb.multiple-links.html
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Home office Ubuntu Server and Work laptop VPN client jehmann Linux - Laptop and Netbook 3 12-09-2013 01:21 PM
VPN client should not connect to special server nima0102 Linux - Networking 3 02-20-2009 11:31 AM
pptp client does not connect to poptop vpn server atomixx Linux - Networking 0 09-24-2008 04:56 AM
linux ppp client fails to connect to linux pptpd serve, works with windows vpn server wastingtime Linux - Server 3 09-20-2008 08:13 PM
How do i connect Ciscos VPN client to Checkpoint VPN server Klas Linux - Networking 1 11-29-2003 08:00 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration