Code: Select all
client-connect /etc/openvpn/client_status.sh
client-disconnect /etc/openvpn/client_status.sh
Code: Select all
#!/bin/bash
cd `dirname $0` #switch to directory of client_status.sh
/usr/local/bin/node client_status --mode=$script_type --ip=$ifconfig_pool_remote_ip --name=$common_name
exit 0
What I did is to solve the porblem is to change script to fork the node process.
Code: Select all
/usr/local/bin/node client_status --mode=$script_type --ip=$ifconfig_pool_remote_ip --name=$common_name &
Is this a bug in openvpn? I can't find any part in documentation which talk about this.
I am using OpenVPN 2.2.1 on ubuntu 12.04 64bit.