reporting icon indicating copy to clipboard operation
reporting copied to clipboard

[BUG] Unable to delete reporting created index .opendistro-reports-definitions

Open daanbosch opened this issue 2 years ago • 3 comments

Describe the bug Unable to delete reporting created index.

To Reproduce Try to delete/change the index

Expected behavior Index is deleted

Plugins opensearch-alerting 1.3.6.0 opensearch-anomaly-detection 1.3.6.0 opensearch-asynchronous-search 1.3.6.0 opensearch-cross-cluster-replication 1.3.6.0 opensearch-index-management 1.3.6.0 opensearch-job-scheduler 1.3.6.0 opensearch-knn 1.3.6.0 opensearch-ml 1.3.6.0 opensearch-observability 1.3.6.0 opensearch-performance-analyzer 1.3.6.0 opensearch-reports-scheduler 1.3.6.0 opensearch-security 1.3.6.0 opensearch-sql 1.3.6.0 prometheus-exporter 1.3.6.0

Screenshots

curl -XDELETE -sk 'https://user:[email protected]:9200/.opendistro-reports-definitions'
{"error":{"root_cause":[{"type":"security_exception","reason":"no permissions for [] and User [name=daan, backend_roles=[, superadmin, admin, all_access], requestedTenant=null]"}],"type":"security_exception","reason":"no permissions for [] and User [name=daan, backend_roles=[, superadmin, admin, all_access], requestedTenant=null]"},"status":403}

Host/Environment (please complete the following information): K8s using the opster operator https://github.com/Opster/opensearch-k8s-operator

Additional context The reason why I want to delete it, is that there are no replica's of this shard and it caused the cluster to be red.

daanbosch avatar Jan 09 '23 13:01 daanbosch

Found a solution for the issue:

curl -XDELETE -k --cert ./kirk.pem --key ./kirk-key.pem  'https://localhost:9200/.opendistro-reports-definitions''

If you use the certificate to authenticate, you will be able to delete the index.

What I do not understand though, is the difference of using the cert versus the basic auth user. Maybe someone could explain the difference to me.

It would also be helpful if these plugins will create shards with at least one replica by default.

daanbosch avatar Jan 10 '23 13:01 daanbosch

I'll move this to opensearch-devops, hopefully someone will know!

dblock avatar Jan 10 '23 16:01 dblock

Actually looks like this is coming from reporting ...

dblock avatar Jan 10 '23 17:01 dblock