[SOLVED] vzdump-hook log message missing on e-mail notification

whinpo

Renowned Member
Jan 11, 2010
140
0
81
Hi,

I'm setting up an hook script for vzdump with a mailnotification enabled.
I don't get the the same messages on the console and on the e-mail.
That's a problem because all the job-start messages are missing (lines :
INFO: HOOK: start job-start
INFO: HOOK-ENV: dumpdir=/mnt/pve/ProxmoxTest-Andromede4/dump;storeid=ProxmoxTest-Andromede4

)
and most of my code will be located in this phase, so I need the logs to appear.
What am I doing wrong ?


Code:
INFO: starting new backup job: vzdump --storage ProxmoxTest-Andromede4 --all 1
INFO: HOOK: start job-start
INFO: HOOK-ENV: dumpdir=/mnt/pve/ProxmoxTest-Andromede4/dump;storeid=ProxmoxTest-Andromede4
INFO: Starting Backup of VM 102 (qemu)
INFO: status = stopped
INFO: VM is locked (backup)
ERROR: Backup of VM 102 failed - command 'qm set 102 --lock backup' failed: exit code 255
Use of uninitialized value in concatenation (.) or string at /usr/share/perl5/PVE/VZDump.pm line 696.
I....

email :
Code:
....
Detailed backup logs:

vzdump --storage ProxmoxTest-Andromede4 --all 1

102: Jul 05 15:17:32 INFO: Starting Backup of VM 102 (qemu)
102: Jul 05 15:17:32 INFO: status = stopped
102: Jul 05 15:17:34 INFO: VM is locked (backup)
102: Jul 05 15:17:34 ERROR: Backup of VM 102 failed - command 'qm set 102 --lock backup' failed: exit code 255
102: Jul 05 15:17:34 INFO: Use of uninitialized value $hostname in concatenation (.) or string at /usr/local/sbin/vzdump-hook-script.pl line 49.
102: Jul 05 15:17:34 INFO: HOOK: start backup-abort 102
102: Jul 05 15:17:34 INFO: HOOK-ENV: vmtype=qemu;dumpdir=/mnt/pve/ProxmoxTest-Andromede4/dump;storeid=ProxmoxTest-Andromede4;hostname=;tarfile=/mnt/pve/ProxmoxTest-Andromede4/dump/vzdump-qemu-102-2016_07_05-15_17_32.vma;logfile=/mnt/pve/ProxmoxTest-Andromede4/dump/vzdump-qemu-102-2016_07_05-15_17_32.log

version :
Code:
root@proxmoxbackup:~# pveversion -v
proxmox-ve: 4.2-56 (running kernel: 4.4.13-1-pve)
pve-manager: 4.2-15 (running version: 4.2-15/6669ad2c)
pve-kernel-4.4.6-1-pve: 4.4.6-48
pve-kernel-4.4.13-1-pve: 4.4.13-56
lvm2: 2.02.116-pve2
corosync-pve: 2.3.5-2
libqb0: 1.0-1
pve-cluster: 4.0-42
qemu-server: 4.0-83
pve-firmware: 1.1-8
libpve-common-perl: 4.0-70
libpve-access-control: 4.0-16
libpve-storage-perl: 4.0-55
pve-libspice-server1: 0.12.5-2
vncterm: 1.2-1
pve-qemu-kvm: 2.5-19
pve-container: 1.0-70
pve-firewall: 2.0-29
pve-ha-manager: 1.0-32
ksm-control-daemon: 1.2-1
glusterfs-client: 3.5.2-2+deb8u2
lxc-pve: 1.1.5-7
lxcfs: 2.0.0-pve2
cgmanager: 0.39-pve1
criu: 1.6.0-1
zfsutils: 0.6.5.7-pve10~bpo80
root@proxmoxbackup:~#

Regards
 
the email only contains the logs from the individual VM backup tasks, not the whole backup job. it might make sense to change this though - could you file a feature request at bugzilla.proxmox.com for this?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!