Hi,
I'm using a simple perl script to add hosts in a DM environment.
I'm now strungling that I cannot add hosts on one of the nodes (it works well with the other)
The error message itself is "No permissions to referred object or it does not exist!'"
Does someone know what exactly this means? Is it somehow possible to exactly know which object it refers to?
I've verified templateid and 100100000000006 and they are correct (actually I retrieve them via another JSON call)
Here my JSON request:
$VAR1 = {
'auth' => '2372ffb05694d2ee7295837a74c8f7e0',
'params' => {
'interfaces' => [
{
'dns' => '',
'useip' => 1,
'ip' => '10.0.2.152',
'type' => 2,
'port' => 10050,
'main' => 1
}
],
'nodeids' => 1,
'groups' => [
{
'groupid' => '100100000000006'
}
],
'name' => 'FAEGFE02',
'output' => 'extend',
'templates' => [
{
'templateid' => '100100000010089'
}
],
'host' => 'FAEGFE02'
},
'jsonrpc' => '2.0',
'id' => 3,
'method' => 'host.create'
};
and the response :
$VAR1 = bless( {
'version' => 0,
'content' => {
'jsonrpc' => '2.0',
'error' => {
'data' => 'No permissions to referred object or it does not exist!',
'message' => 'Application error.',
'code' => -32500
},
'id' => 3
},
'jsontext' => '{"jsonrpc":"2.0","error":{"code":-32500,"message":"Application error.","data":"No permissions to referred object or it does not exist!"},"id":3}',
'is_success' => 0
}, 'JSON::RPC::Legacy::ReturnObject' );
I'm using a simple perl script to add hosts in a DM environment.
I'm now strungling that I cannot add hosts on one of the nodes (it works well with the other)
The error message itself is "No permissions to referred object or it does not exist!'"
Does someone know what exactly this means? Is it somehow possible to exactly know which object it refers to?
I've verified templateid and 100100000000006 and they are correct (actually I retrieve them via another JSON call)
Here my JSON request:
$VAR1 = {
'auth' => '2372ffb05694d2ee7295837a74c8f7e0',
'params' => {
'interfaces' => [
{
'dns' => '',
'useip' => 1,
'ip' => '10.0.2.152',
'type' => 2,
'port' => 10050,
'main' => 1
}
],
'nodeids' => 1,
'groups' => [
{
'groupid' => '100100000000006'
}
],
'name' => 'FAEGFE02',
'output' => 'extend',
'templates' => [
{
'templateid' => '100100000010089'
}
],
'host' => 'FAEGFE02'
},
'jsonrpc' => '2.0',
'id' => 3,
'method' => 'host.create'
};
and the response :
$VAR1 = bless( {
'version' => 0,
'content' => {
'jsonrpc' => '2.0',
'error' => {
'data' => 'No permissions to referred object or it does not exist!',
'message' => 'Application error.',
'code' => -32500
},
'id' => 3
},
'jsontext' => '{"jsonrpc":"2.0","error":{"code":-32500,"message":"Application error.","data":"No permissions to referred object or it does not exist!"},"id":3}',
'is_success' => 0
}, 'JSON::RPC::Legacy::ReturnObject' );
Comment