OpenVPN on Chromebook with crouton

After hours trying to get a VPN connection up with issues like Cannot find device ¨tun0" or Linux ip addr del failed: external program exited with error status: 1, I found this post on the Crouton github issues that made setting up VPN tunnels work as it should: download the client.ovpn config and simply sudo openvpn client.opvn.

Quoting the issue from the post >HI, I think I found a reliable solution to make openvpn command working. The tun0 interface is destroyed by the shill service which automatically kills the “useless” connections.

The solution is to enter the following commands before openvpn:
sudo stop shill
sudo start shill BLACKLISTED_DEVICES=tun0
the BLACKLISTED_DEVICES tells shill to ignore the “tun0” device.

So wrapping the openvpn command in a small script and running it from the ChromeOS shell, does the trick ! Then I have the VPN automatically available for all my Crouton shells.