DEV Community

Cover image for Fixing OpenVPN Connection Issues in Ubuntu
MUHAMMED YAZEEN AN
MUHAMMED YAZEEN AN

Posted on Edited on

Fixing OpenVPN Connection Issues in Ubuntu

If you've recently upgraded to Ubuntu 24.04 and are experiencing issues with OpenVPN connections failing silently after importing a .ovpn profile, you're not alone. This is a common problem that many users have encountered. Fortunately, it can be resolved using one of two methods: editing the .ovpn file directly or adjusting settings through the GUI.

Method 1: Edit the .ovpn Profile

Step 1: Import the .ovpn Profile

Start by importing the .ovpn profile into Ubuntu's Network Settings:

  1. Open Settings on your Ubuntu system.
  2. Navigate to the Network tab.
  3. Under the VPN section, click the + button.
  4. Select Import from file and choose your .ovpn file.

Once imported, try connecting to the VPN. If the connection fails silently, proceed with the following steps.

Step 2: Edit the .ovpn File

  1. Open the .ovpn file you imported using a text editor.
  2. Locate the line that says:
   cipher AES-256-CBC
Enter fullscreen mode Exit fullscreen mode
  1. Comment out this line by adding a # at the beginning:
   #cipher AES-256-CBC
Enter fullscreen mode Exit fullscreen mode
  1. Save the file.

Step 3: Re-import the Edited Profile

  1. Go back to Network Settings and remove the existing VPN profile.
  2. Click the + button again and re-import the edited .ovpn file.

Step 4: Reconnect to the VPN

Try reconnecting to the VPN. The connection should now work without any issues.


Method 2: Change Cipher Settings via GUI

If you prefer not to edit the .ovpn file directly, you can resolve the issue through the Network Settings GUI.

Step 1: Import the .ovpn Profile

Follow the same steps as in Method 1 to import your .ovpn profile:

  1. Open Settings and go to the Network section.
  2. Click the + button under the VPN section and select Import from file.
  3. Choose your .ovpn profile.

Step 2: Open VPN Profile Settings

  1. After importing, click the gear icon next to the VPN profile to open its settings.

Step 3: Navigate to Advanced Settings

  1. In the Identity tab, scroll down to the Advanced section.
  2. Click on Advanced Options to open the advanced properties modal.

Step 4: Change the Cipher

  1. Under the Security section, locate the dropdown for Cipher.
  2. Change the Cipher from AES-256-CBC to Default.
  3. Save the changes and close the modal.

Step 5: Reconnect to the VPN

After saving the changes, try reconnecting to the VPN. The connection should now work properly.


I hope this helps :)

Top comments (0)