Ad Widget

Collapse

Item not returning anything when using /usr/bin/timeout

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mimizone
    Junior Member
    • Sep 2015
    • 1

    #1

    Item not returning anything when using /usr/bin/timeout

    Hi,
    I wanted to use /usr/bin/timeout to kill an openvpn connection after 10s.

    My item is a UserParameter set up as follow:

    UserParameter=vpn[*],/usr/bin/timeout 10 /usr/sbin/openvpn $1.ovpn

    everything is great when the timeout is not triggered (basically that openvpn works). I can see the logs in the item on zabbix.

    but when the timeout is triggered, the item is never refreshed.

    I've tried shielding it with "bash -c" or change the signal of the timeout to 3 and 15 but it doesn't solve the problem.

    I also replaced timeout with the --tls-exit option of openvpn, but the same behavior is experienced in that case.
    Same issue if I let openvpn timeout itself after 5 retries.

    Any recommendation on how to go around this problem?
Working...