Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15

Thread: OpenVPN routing problem

  1. #11
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,241
    Blog Entries
    1

    Default Re: OpenVPN routing problem

    Quote Originally Posted by Kumulus View Post
    Unfortunately its not working when I add "route-delay 4" (or 10 )to client config.
    What can I do now to make it permanent.

    I just dont understand why I can add route manually but not thru client config.
    Is he pushing right routes ?
    Code:
     ERROR: Nexthop has invalid gateway. ERROR: Linux route add command failed: external program exited with error status: 2
    Code:
    TUN/TAP device tap0 opened
    Mon Apr  6 22:13:20 2020 us=902000 TUN/TAP TX queue length set to 100
    Mon Apr  6 22:13:24 2020 us=370196 /bin/ip route add 89.164.xxx.yyy/32 via 10.1.0.1
    Mon Apr  6 22:13:24 2020 us=371619 /bin/ip route add 0.0.0.0/1 via 192.168.1.1
    Error: Nexthop has invalid gateway.
    Mon Apr  6 22:13:24 2020 us=372822 ERROR: Linux route add command failed: external program exited with error status: 2
    Mon Apr  6 22:13:24 2020 us=372861 /bin/ip route add 128.0.0.0/1 via 192.168.1.1
    Error: Nexthop has invalid gateway.
    As you can see the gateway doesn't exist, since tap0 doesn't yet have an address assigned. I'm not sure why the regression exists though and a bug report might be needed. Does adding a longer route delay help?
    openSUSE Leap 15.1; KDE Plasma 5

  2. #12
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,241
    Blog Entries
    1

    Default Re: OpenVPN routing problem

    Quote Originally Posted by Kumulus View Post
    This is my client config
    Code:
    dev tap
    persist-tun
    persist-key
    cipher AES-256-CBC
    ncp-disable
    auth SHA512
    tls-client
    client
    resolv-retry infinite
    remote my-name.org 1194 udp
    route-gateway 192.168.1.1
    remote server 1194
    lport 0
    verify-x509-name "OpenVpn Server" name
    remote-cert-tls server
    #fragment 0
    #float
    comp-lzo adaptive
    tun-mtu 1500
    auth-nocache
    route-delay 10
    verb 4
    When I remove route-gateway 192.168.1.1 from config I get
    Code:
    NOTE: unable to redirect default gateway -- VPN gateway parameter (--route-gateway or --ifconfig) is missing
    Yes, don't do that.
    openSUSE Leap 15.1; KDE Plasma 5

  3. #13
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,241
    Blog Entries
    1

    Default Re: OpenVPN routing problem

    Can you post your working sever configuration? Are you using DHCP or pushing a static IP address? I'm wondering if the server and/or client config just needs tuning. Which guide were you following?

    –route-gateway gw|’dhcp’Specify a default gateway gw for use with –route.If dhcp is specified as the parameter, the gateway address will be extracted from a DHCP negotiation with the OpenVPN server-side LAN.
    Last edited by deano_ferrari; 06-Apr-2020 at 14:39.
    openSUSE Leap 15.1; KDE Plasma 5

  4. #14
    Join Date
    Jan 2020
    Location
    Zagreb, HR
    Posts
    6

    Default Re: OpenVPN routing problem

    Adding longer delay is not working.
    I`m using OpenVpn TAP server on pfSense box. And using single DHCP to provide address to LAN and OpenVpn.
    I have assigned one part of the range for DHCP and other smaller to give fix IP.
    Don`t know how to export OpenVpn settings from pfSense.

    I'm wondering if the server and/or client config just needs tuning. Which guide were you following?
    Maybe in client config instead --route-gateway using --ifconfig to assign IP.
    I have this setup for some years but I didn't have real need to use PC to connect. And Android was working.

    Maybe I do have to fill bug report. But to whom, OpenVpn or OpenSuse ? I am new to OS community.

  5. #15
    Join Date
    Jun 2008
    Location
    Auckland, NZ
    Posts
    21,241
    Blog Entries
    1

    Default Re: OpenVPN routing problem

    Perhaps try the OpenVPN Forums first.
    openSUSE Leap 15.1; KDE Plasma 5

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •