1

First, the working scenario. One OpenVPN client (2.1~rc11 under ubuntu 9.04) connects to a OpenvPN server (2.1~rc11 ubuntu 8.10) using a ethernet interface (eth0). Both use TUN device and UDP connection. But when I turn on the wireless interface (ifup wlan0) in the client ,the host can't communicate with the server anymore. I read a bit about the problem but didn't found a working solution. Maybe setting some iptable rules to mark the incoming datagrams to output them through the same interface. Any help would be appreciated.

Thanks in advance

1 Answer 1

0

First of all, iptableS won't help when traffic is generated in your scenario. I suspect that when you turn on the wireless interface you have two default gateways; you can verify that by typing route -n and by checking how many lines starting with 0.0.0.0 you can see. If this is the case, you need to delete one default route.

If this is not the case, do check the linux advanced routing and traffic control howto (LARTC). Using the ip command will help you to set up tables to route specific traffic on single interfaces, so on and so forth.

2
  • Thanks lorenzog. Yes, two default routes (0.0.0.0) are present. One for wlan0 and the other for eth0. When each interface starts it sets up a default gateway, and that "confuses" OpenVPN. I'll check the documentation you gave me.
    – Humber
    Dec 9, 2009 at 14:18
  • Humber, you can always manually delete one of the default gateways via a script that checks whether there is another default gateway already set before digging yourself into advanced routing.
    – lorenzog
    Dec 9, 2009 at 15:10

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .