Quantcast
Channel: Active questions tagged openvpn - Unix & Linux Stack Exchange
Viewing all articles
Browse latest Browse all 827

xl commands don't work in openvpn scripts

$
0
0

I have script with xl command (Xen 4.9) which run by OpenVPN (Ubuntu 19.04).

In my openvpn config:

script-security 2 up /etc/xen/scripts/vpn.sh

In my script commans like this:

TEST=`xl domid test`

So. If I run this script in root console everything is good, but OpenVPN (systemd, run by root) excute this scripts with error like this:

xencall: error: Could not obtain handle on privileged command interface: Operation not permittedlibxl: error: libxl.c:102:libxl_ctx_alloc: cannot open libxc handle: Operation not permittedcannot init xl context

OpenVPN run by root (systemd):

root@MS /etc/openvpn # ps -Af|grep openvpnroot      3257     1  0 02:08 ?        00:00:01 /usr/sbin/openvpn --daemon ovpn-b2b --status /run/openvpn/b2b.status 10 --cd /etc/openvpn --script-security 2 --config /etc/openvpn/b2b.conf --> writepid /run/openvpn/b2b.pid

If I run OpenVPN with similar config in root console, script is run without error. What is problem?


Viewing all articles
Browse latest Browse all 827

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>