Cannot create user

I post this, with xpack enabled and trial license

curl -X POST "https://127.0.0.1:9200/_xpack/security/role/demo_admin" -u elastic:password -k -H "Content-Type: application/json" --data '{"indices": [{"names": [ "*" ],"privileges":[ "manage" ]}]}'

and get this back
{"error":{"root_cause":[{"type":"unavailable_shards_exception","reason":"[.security-7][0] primary shard is not active Timeout: [1m], request: [BulkShardRequest [[.security-7][0]] containing [index {[.security][_doc][role-demo_admin], source[{"cluster":,"indices":[{
"names":[""],"privileges":["manage"],"allow_restricted_indices":false}],"applications":[],"run_as":[],"metadata":{},"type":"role"}]}] and a refresh]"}],"type":"unavailable_shards_exception","reason":"[.security-7][0] primary shard is not active Timeout
: [1m], request: [BulkShardRequest [[.security-7][0]] containing [index {[.security][_doc][role-demo_admin], source[{"cluster":[],"indices":[{"names":["
"],"privileges":["manage"],"allow_restricted_indices":false}],"applications":,"run_as":,"metadat
a":{},"type":"role"}]}] and a refresh]"},"status":503}

What am I missing?

(Sorry about the - not sure yet how to avoid these being parsed incorrectly by the forum UI.)

What does your node configuration look like? Do you have any non-default settings, e.g. node.data: false?

That was it. Thanks for suggesting!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.