Jump to content


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.

Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.


OpenVPN - Can't get client traffic through VPN server

  • Please log in to reply
1 reply to this topic

#1 thejestre


  • Members
  • 25 posts
  • Local time:09:11 AM

Posted 03 October 2011 - 12:52 PM


I have set up OpenVPN once before, but I'm very new at networking Linux. I had successfully done this on Ubuntu 8.10, now I'm trying to do the same thing on Ubuntu 10.04. I think the general setup is correct because when I connect the client to the server I can successfully SSH and FTP to the server.

What I want to do is force all client traffic [including web] through the VPN server. I tried to NAT [correct term?] it with this:
sudo iptables -t nat -A POSTROUTING -s -o eth0 -j MASQUERADE
But no go. The above command accomplished what I wanted on my old server. Any ideas? I'll post both config files below.

All suggestions appreciated,



port X

proto udp

dev tun

ca /etc/openvpn/keys/ca.crt
cert /etc/openvpn/keys/server.crt
key /etc/openvpn/keys/server.key  # This file should be kept secret

dh /etc/openvpn/keys/dh1024.pem


ifconfig-pool-persist ipp.txt

client-config-dir ccd

push "redirect-gateway def1"

push "dhcp-option DNS" 

keepalive 10 120

cipher AES-128-CBC   # AES

max-clients 5

user nobody
group nogroup


status openvpn-status.log

log         openvpn.log

verb 4

mute 10



dev tun

proto udp

remote A.B.C.D X

resolv-retry infinite




ca Lease-ca.crt
cert thejestre.crt
key thejestre.key

ns-cert-type server

cipher AES-128-CBC

verb 4

BC AdBot (Login to Remove)


#2 thejestre

  • Topic Starter

  • Members
  • 25 posts
  • Local time:09:11 AM

Posted 04 October 2011 - 12:19 AM


I'm trying to set up OpenVPN on a dedicated server I'm renting. It runs Ubuntu 10.04 and I have OpenVPN installed 'successfully' but I can't get it to do what I want. I don't know much about troubleshooting network issues in Linux.

What it does now:
I can successfully connect from my home client computer [XP SP3] to the dedicated OpenVPN dedicated server using the OpenVPN GUI for Windows. It connects and I can do normal services [ssh, ftp] with the dedicated. OpenVPN is set up to use for private addressing. I cannot successfully ping or when connected to the VPN.

I followed this tutorial:
But still can't get traffic forwarded _through_ the server.

Anyone know what log files I should look at to see where the problem is?

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users