Skip to content

Error monitoring a large number of jobs #2

@Zhenja86

Description

@Zhenja86

I found an error. bacula_check_job script creates a temporary file / tmp / bacula_konf variables for later export.
The problem is that at the end of the script file is deleted.
And a large number of jobs there is a situation when a temporary file is removed or not fully recorded at the time of export
danyh another instance bacula_check_job.

And so sometimes come zabbix data type:
/etc/zabbix/scripts/bacula_check_job: line 8: /tmp/bacula_conf: No such file or directory
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
ERROR 1102 (42000): Incorrect database name 'SELECT jobstatus FROM Job WHERE name='

This leads to some false alarm triggers.

The problem is easily solved if for each duplicate of the script / etc / zabbix / scripts / bacula_check_job create a unique image.
By adding the first argument to the file name. The first argument is the name of the job - it is unique for each request.

I prepared a patch to solve this problem. Perhaps there is a better solution.

bacula_check_job_Patch.diff.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions