romainsi/zabbix-VEEAM_B-R

Problem with zabbix_sender.exe or something.

thuban-arrakis opened this issue · 6 comments

Hello, my friend.
Thanx for your work, but i have some issues with that.
Windows Server 2012R2, x64.
VBR version - 9.5
zabbix_agentd.exe - 3.4.6

image

$pathxml = 'C:\Program Files\Zabbix Agent\scripts'
All .xml files has been created successfully.
$pathsender = 'C:\Program Files\Zabbix Agent\bin\win64'
zabbix_agentd.win.conf copied in both path's, for shure, so whatever about that.

So, here is a thing.
In front of vbr["DiscoveryRepo"] key i have a warning - Value should be a JSON object.

image

10.6.1.2 - IP of my Veeam server

[root@ch-srv-zabbix ~]# zabbix_get -k vbr["DiscoveryRepo"] -s 10.6.1.2
{"data":[{"{#REPONAME}":"MSA\Backup\RingMaster_cfg"},{"{#REPONAME}":"MSA\Backup\VM"},{"{#REPONAME}":"MSA\Backup"},{"{#REPONAME}":"MSA\Backup\SQL"},{"{#REPONAME}":"Default Backup Repository"}]}
[root@ch-srv-zabbix ~]#

image

But, lastets data in zabbix frontend shows me small amount of collected information.

image

[root@ch-srv-zabbix ~]# zabbix_get -k vbr[VmCount,a0bbde57-eecf-4451-b866-a12049d800c9] -s 10.6.1.2
1
[root@ch-srv-zabbix ~]# zabbix_get -k vbr[NextRunTime,a0bbde57-eecf-4451-b866-a12049d800c9] -s 10.6.1.2
1535178960

My zabbix_agent.win.conf

LogFile=c:\zabbix_agentd.log
LogFileSize=3
DebugLevel=4
EnableRemoteCommands=1
Server=10.6.1.43
ListenPort=10050
ServerActive=10.6.1.43:10051
Hostname=CH-SRV-BACKUPS
Alias=service.discovery.veeam:service.discovery
Timeout=30
UnsafeUserParameters=1
UserParameter=vbr[*],powershell -NoProfile -ExecutionPolicy Bypass -File "C:\Program Files\Zabbix Agent\scripts\zabbix_vbr_job.ps1" "$1" "$2"

Trappers in zabbix_server.conf

[root@ch-srv-zabbix ~]# cat /etc/zabbix/zabbix_server.conf | grep StartTrappers
### Option: StartTrappers
# StartTrappers=5
StartTrappers=5

image

Hi!

For the discovery repository (vbr["DiscoveryRepo"]) your repository name is not correct, in JSON the character \ is not valid.
For that, I can escape special characters.... (no time at the moment.....).
You can delete special characters in repository names to solve your problem :)

For the 2sd problem without data in the classic job discovery, can you check your return JSON zabbix_get -k vbr["Discovery"] -s 10.6.1.2 with jsonlint.com for example?
Did you wait for the discovery time 7200s / 2 hours or change it (example: 5mn).

But if it works with the zabbix_get commands, it's strange ^^.

I am using Windows 2012R2 (Update)
Veeam B&R v9.5 (Latest version)

Ps : Maybe you can find your happiness in the closed tickets :
https://github.com/romainsi/zabbix-VEEAM_B-R_jobs_trapper/issues?q=is%3Aissue+is%3Aclosed

can you check your return JSON zabbix_get -k vbr["Discovery"] -s 10.6.1.2 with jsonlint.com for example?

image
image

Did you wait for the discovery time 7200s / 2 hours or change it (example: 5mn).

Yes, i did.
And, you know what? Just checked lastest data, and all is fine -____-"
Exept results of job's
image

[root@ch-srv-zabbix /]# zabbix_get -k vbr[Result,32a867e0-17f2-449e-8378-f2ec87e69b69] -s 10.6.1.2 Execution reussie

Hi,

Discovery of Job work ?
Have you item trapper created in zabbix like : Result.[7a2c8255-9916-45cc-a280-3d6a090f4364] ?

Result of Job use Zabbix Sender, you can test like that :

In your veeam server open Powershell console :
cd "C:\Program Files\Zabbix Agent"
./zabbix_sender.exe -c .\zabbix_agentd.conf -k Result.[7a2c8255-9916-45cc-a280-3d6a090f4364] -o 1 -v

Ajust command with your JobId and location of parameters.

In your veeam server open Powershell console :
cd "C:\Program Files\Zabbix Agent"
./zabbix_sender.exe -c .\zabbix_agentd.conf -k Result.[7a2c8255-9916-45cc-a280-3d6a090f4364] -o 1 -v

PS C:\Program Files\Zabbix Agent\bin\win64> .\zabbix_sender.exe -c .\zabbix_agentd.win.conf -k Result.[32a867e0-17f2-449e-8378-f2ec87e69b69] -o 1 -v
info from server: "processed: 1; failed: 0; total: 1; seconds spent: 0.000211"
sent: 1; skipped: 0; total: 1
PS C:\Program Files\Zabbix Agent\bin\win64>

Then Job Warning appears in Zabbix Dashboard.
I've changed previous command with -o 2 -v, and get ok status to this job.

Have you item trapper created in zabbix like : Result.[7a2c8255-9916-45cc-a280-3d6a090f4364] ?

Yes, it is.
image
Maybe i should set up interval?

You've no interval in Item Trapper. Key just wait value.

If you check "see details" in your last data in zabbix you can see if you have an error and details.

Look my screen with data :

image

Ok, thank you very much for help. I think, at this point, all works fine.
Good Luck.