How To Reproduce OVPN Problem

networking
instructions

In this post I will explain the steps required to measure and reproduce the issue with OVPN Public IPv4.

The Issue

The issue I had with OVPN Public IPv4 was that it would dis- and reconnect every 10 minutes.

Measuring Network Disconnections

I use dpinger to measure network disconnections. I wasn’t able to measure it with just ping for some reason.

Installing dpinger on Windows

dpinger requires linux to run. For this reason, you have to use Windows Subsystem for Linux (WSL) to run it. The next steps will guide you to install WSL, which you may skip if you have it installed already.

Installing Windows Subsystem for Linux

  1. Run the following command as administrator to install WSL and an operating system (Ubuntu by default):

    wsl --install

    From this point on, you can use the wsl command to launch the default shell.

  2. Launch the Linux shell:

    wsl

Since you are now inside of Ubuntu, you can now continue the steps to install dpinger on Linux.

Installing dpinger on Linux

  1. Install git, make, and clang with apt:

    sudo apt-get install git make clang -y
  2. Clone and open the dpinger repository:

    git clone https://github.com/dennypage/dpinger.git
    cd dpinger
  3. Build dpinger:

    make

Using dpinger

The following command will run dpinger against Cloudflare DNS (1.1.1.1) in the foreground while averaging results for 2s:

sudo ./dpinger -f -t 2s 1.1.1.1

Understanding results

The output format of dpinger is:
latency_avg latency_stddev loss_pct

As long as the internet is connected, it should look something like this:

dpinger Console Window Connected

When the internet suddenly disconnects, it will look like this:

dpinger Console Window Disconnected

I’m not sure why it shows packet loss as 0. I’ve also seen packet loss at 100 once, but since no packets go through, the latencies can’t be calculated and thus it shows the latencies as 0.

Measuring the OVPN Static IPv4 Problem

  1. Download and install the OVPN App as instructed here.

  2. Open the OVPN App.

  3. The problem only occurs with the Public IPv4 Addon, so choose “Public IPv4”: Select OVPN Public IPv4 Addon

  4. Click Connect: Click OVPN Connect

  5. Run dpinger:

    sudo ./dpinger -f -t 2s 1.1.1.1
  6. Wait at least 10min for the VPN to disconnect and watch the output. When a disconnection occurs, it will look like this: Click OVPN Connect