Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Examples needed #125

Open
moridius opened this issue Jun 1, 2020 · 1 comment
Open

Examples needed #125

moridius opened this issue Jun 1, 2020 · 1 comment

Comments

@moridius
Copy link

moridius commented Jun 1, 2020

I'm trying to move a host to maintenance mode but I'm struggling with the syntax. The documentation names the parameters, which is great, but it doesn't show how to pass them over (at least I didn't find it).
I tried this:
zabbix-cli -C "create_maintenance_definition \"'name':'a','description':'b','host':'c','time period':'30 minutes','maintenance type':'0'\""

Result:
[Error]: Wrong number of parameters used. Type help or \? to list commands

@bbrendon
Copy link

bbrendon commented Aug 7, 2020

ROFL.

Oh my god. The docs must be really bad. I came up with something completely different. At one point I starting going down the road you did but reversed course because I was getting ...Wrong number of parameters....

# zabbix-cli -C "create_maintenance_definition sfdame mdesc zinc 1h 0"

[Error]: Problems creating maintenance definition (sfdame)

EDIT
I did some googling and found some working examples...

create_maintenance_definition sfdame mdesc zinc  '2018-04-23T12:00 to 2018-04-23T13:00' 1

create_maintenance_definition sfdadme mdesc zinc  '1 hour' 1

zabbix-cli -C "create_maintenance_definition '' 'Testing maintenance' 'zabbix-mgmt.uio.no' '3 hours'"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants