2

I want to use the gnome-network-manager settings utility to manage my VPNs but it isn't working - and I'm not sure how to debug it.

I am using an ovpn file, so from the cli maybe the network-manager hits the same issue as I do when I run openvpn --config my.ovpn

Thu Nov  1 08:39:52 2018 Data Channel: using negotiated cipher 'AES-128-GCM'
Thu Nov  1 08:39:52 2018 Outgoing Data Channel: Cipher 'AES-128-GCM' initialized with 128 bit key
Thu Nov  1 08:39:52 2018 Incoming Data Channel: Cipher 'AES-128-GCM' initialized with 128 bit key
Thu Nov  1 08:39:52 2018 ERROR: Cannot ioctl TUNSETIFF tun: Operation not permitted (errno=1)
Thu Nov  1 08:39:52 2018 Exiting due to fatal error

This is fixed by running the command with sudo , so I can bypass the network-manager GUI for now but how do I fix it?

Update

I did reboot my computer and tried running sudo pkill vpn as suggested by the first replier. But before that I checked what ps would say, and nothing w/ vpn was running.

➜ sudo ps -ax|grep vpn 
 5536 pts/0    S+     0:00 grep --color vpn

Then I toggle the VPN connection seeing if it worked from either rebooting or the pkill idea and ran that my check is correct:

➜ sudo ps -ax|grep vpn    
 5655 ?        Sl     0:00 /usr/lib/NetworkManager/nm-openvpn-service --bus-name org.freedesktop.NetworkManager.openvpn.Connection_2
 5667 ?        S      0:00 /usr/sbin/openvpn --remote ...
1
  • Did you find a solution?
    – OneAndOnly
    Commented Jun 23, 2023 at 5:28

1 Answer 1

-1

I encounter this error a lot if I forget that I have had an active VPN on from another session, it sometimes gets buggy.

Try running sudo pkill vpn To remove any active openvpn processes. This bug normally only occurs when a VPN remains active through a reboot.

2
  • Nah, there's nothing vpn running compared to when it's trying to make the connection which I can see with: ➜ sudo ps -ax|grep vpn 5536 pts/0 S+ 0:00 grep --color vpn
    – Falieson
    Commented Nov 2, 2018 at 17:17
  • Is your ovpn file owned by root? In some cases running this with sudo will fail if your configuration file is not owned by root.
    – user797940
    Commented Nov 3, 2018 at 18:10

You must log in to answer this question.

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