Hi.
I'm trying to use hook script for a VM. I've enabled the local storage to handle snippets, I put my script in /var/lib/vz/snippets/, with exec permissions, I've configured a test VM to use with
But it looks like it's not executed. The script is working if I execute it manually (with args 150 pre-start for example). To be sure everything is OK, I replaced my script with the sample hook found in /usr/share/pve-docs/examples/guest-example-hookscript.pl (and checkd it has exec permissions). And still, nothing in system's log (journalctl -f). So my question is : is stdout/stderr of hook scripts captured and sent to the log ? If not, what's the best way to debug ?
I'm trying to use hook script for a VM. I've enabled the local storage to handle snippets, I put my script in /var/lib/vz/snippets/, with exec permissions, I've configured a test VM to use with
Code:
qm set 150 -hookscript local:snippets/vm_hook.pl
But it looks like it's not executed. The script is working if I execute it manually (with args 150 pre-start for example). To be sure everything is OK, I replaced my script with the sample hook found in /usr/share/pve-docs/examples/guest-example-hookscript.pl (and checkd it has exec permissions). And still, nothing in system's log (journalctl -f). So my question is : is stdout/stderr of hook scripts captured and sent to the log ? If not, what's the best way to debug ?