Skip to main content

I had a long fight for this but this how I managed to find a workaround the issue in Ubuntu 18 using network-manager and GUI:

Download GUI packagesDownload GUI packages

$ sudo apt-get install network-manager-openvpn network-manager-openvpn-gnome

Network manager change [ifupdown] managed=true

$ sudo nano /etc/NetworkManager/NetworkManager.conf
.
.
[ifupdown]
managed=true
.
.

Import config.ovpnconfig.ovpn from GUI

(Settings -> Network -> VPN -> +)

Check imported connection id from from the connection file that was created automatically. (The file should be named config and id should also be config but they can be something else)

$ sudo grep /etc/NetworkManager/system-connections/config | grep "^id"

Change rendered to NetworkManager and add the new connection id inside the ethernets

$ sudo nano /etc/netplan/01-netcfg.yaml

network:
  version: 2
  renderedrenderer: NetworkManager
  ethernets:
    enp0s25:
      dhcp4: yes
    config:
      dhcp4: yes

Apply changesApply changes

$ sudo netplan apply

Restart network-managerRestart network-manager

$ sudo service network-manager restart

Open the connection either from the GUI or using nmcli

$ nmcli connection up config

I had a long fight for this but this how I managed to find a workaround the issue in Ubuntu 18 using network-manager and GUI:

Download GUI packages

$ sudo apt-get install network-manager-openvpn network-manager-openvpn-gnome

Network manager change [ifupdown] managed=true

$ sudo nano /etc/NetworkManager/NetworkManager.conf
.
.
[ifupdown]
managed=true
.
.

Import config.ovpn from GUI

(Settings -> Network -> VPN -> +)

Check imported connection id from from the connection file that was created automatically. (The file should be named config and id should also be config but they can be something else)

$ sudo grep /etc/NetworkManager/system-connections/config | grep "^id"

Change rendered to NetworkManager and add the new connection id inside the ethernets

$ sudo nano /etc/netplan/01-netcfg.yaml

network:
  version: 2
  rendered: NetworkManager
  ethernets:
    enp0s25:
      dhcp4: yes
    config:
      dhcp4: yes

Apply changes

$ sudo netplan apply

Restart network-manager

$ sudo service network-manager restart

Open the connection either from the GUI or using nmcli

$ nmcli connection up config

I had a long fight for this but this how I managed to find a workaround the issue in Ubuntu 18 using network-manager and GUI:

Download GUI packages

$ sudo apt-get install network-manager-openvpn network-manager-openvpn-gnome

Network manager change [ifupdown] managed=true

$ sudo nano /etc/NetworkManager/NetworkManager.conf
.
.
[ifupdown]
managed=true
.
.

Import config.ovpn from GUI

(Settings -> Network -> VPN -> +)

Check imported connection id from from the connection file that was created automatically. (The file should be named config and id should also be config but they can be something else)

$ sudo grep /etc/NetworkManager/system-connections/config | grep "^id"

Change rendered to NetworkManager and add the new connection id inside the ethernets

$ sudo nano /etc/netplan/01-netcfg.yaml

network:
  version: 2
  renderer: NetworkManager
  ethernets:
    enp0s25:
      dhcp4: yes
    config:
      dhcp4: yes

Apply changes

$ sudo netplan apply

Restart network-manager

$ sudo service network-manager restart

Open the connection either from the GUI or using nmcli

$ nmcli connection up config
Source Link

I had a long fight for this but this how I managed to find a workaround the issue in Ubuntu 18 using network-manager and GUI:

Download GUI packages

$ sudo apt-get install network-manager-openvpn network-manager-openvpn-gnome

Network manager change [ifupdown] managed=true

$ sudo nano /etc/NetworkManager/NetworkManager.conf
.
.
[ifupdown]
managed=true
.
.

Import config.ovpn from GUI

(Settings -> Network -> VPN -> +)

Check imported connection id from from the connection file that was created automatically. (The file should be named config and id should also be config but they can be something else)

$ sudo grep /etc/NetworkManager/system-connections/config | grep "^id"

Change rendered to NetworkManager and add the new connection id inside the ethernets

$ sudo nano /etc/netplan/01-netcfg.yaml

network:
  version: 2
  rendered: NetworkManager
  ethernets:
    enp0s25:
      dhcp4: yes
    config:
      dhcp4: yes

Apply changes

$ sudo netplan apply

Restart network-manager

$ sudo service network-manager restart

Open the connection either from the GUI or using nmcli

$ nmcli connection up config