Hello All,
I am trying to use zabex.py library to create a new item and add data value like below but I am getting Invalid params, No Permissions error:
root@cast2:~# python zabex.py
[u'Zabbix server', u'cast2']
Traceback (most recent call last):
File "zabex.py", line 20, in <module>
zapi.item.create(name="something", key_ = 'system.cpu.num', hostid='cast2', value_type=3, type=0)
File "/usr/local/lib/python2.7/dist-packages/pyzabbix/api.py", line 82, in fn
args or kwargs
File "/usr/local/lib/python2.7/dist-packages/pyzabbix/api.py", line 250, in do_request
raise ZabbixAPIException(msg, err['code'])
pyzabbix.api.ZabbixAPIException: ("Error -32602: Invalid params., No permissions to referred object or it does not exist! while sending {'params': {'value_type': 3, 'hostid': 'cast2', 'key_': 'system.cpu.num', 'name': 'something', 'type': 0}, 'jsonrpc': '2.0', 'method': 'item.create', 'auth': u'993b6d9be8293e8e0e502b39f1300d7d', 'id': '1'}", -32602)
Looking for some urgent help.
I am trying to use zabex.py library to create a new item and add data value like below but I am getting Invalid params, No Permissions error:
root@cast2:~# python zabex.py
[u'Zabbix server', u'cast2']
Traceback (most recent call last):
File "zabex.py", line 20, in <module>
zapi.item.create(name="something", key_ = 'system.cpu.num', hostid='cast2', value_type=3, type=0)
File "/usr/local/lib/python2.7/dist-packages/pyzabbix/api.py", line 82, in fn
args or kwargs
File "/usr/local/lib/python2.7/dist-packages/pyzabbix/api.py", line 250, in do_request
raise ZabbixAPIException(msg, err['code'])
pyzabbix.api.ZabbixAPIException: ("Error -32602: Invalid params., No permissions to referred object or it does not exist! while sending {'params': {'value_type': 3, 'hostid': 'cast2', 'key_': 'system.cpu.num', 'name': 'something', 'type': 0}, 'jsonrpc': '2.0', 'method': 'item.create', 'auth': u'993b6d9be8293e8e0e502b39f1300d7d', 'id': '1'}", -32602)
Looking for some urgent help.
Comment