Ahoj,
uz nevim kudy. Elasticsearch 8.x, zkousim zkopirovat uzivatele z jednoho clusteru do druheho bez pouziti snapshotu. Nasel jsem spousta navodu na elasticdump:
Dump:
# node_modules/.bin/elasticdump --debug --input=https://restore_user:SOMEPWD@SRC:9200/.security-7 --output=/tmp/.security.json
Restore
node_modules/.bin/elasticdump --debug --output=https://restore_user:SOMEPWD@DEST:9200/.security-7 --input=/tmp/.security.json
...
{
_index: '.security-7',
_id: 'user-SOMEUSER',
status: 403,
error: {
type: 'security_exception',
reason: 'action [indices:data/write/bulk[s]] is unauthorized for user [restore_user] with effective roles [restore_role] on restricted indices [.security-7], this action is granted by the index privileges [create_doc,create,delete,index,write,all]'
}
}
Fri, 11 Jul 2025 08:43:10 GMT | sent 63 objects, 0 offset, to destination elasticsearch, wrote 0
Fri, 11 Jul 2025 08:43:10 GMT | Total Writes: 0
Fri, 11 Jul 2025 08:43:10 GMT | dump complete
To indices:data/write/bulk[s]
jsem nasel jako acl v Opensearch, ale v ES nic takoveho neni. Vi nekdo, jak na to? Zkousel jsem tomu dat veskere mozne role (samozrejme i all/superuser atd.), ktere nejsou aplikacne specificke (napr. kibana_* atd.)
Pro testovani migrace pres snapshot jeste nemam zprovoznene sitove uloziste. Testovani pripojenim serveru "noveho" do "stareho" ES a nejakym typem replikace se mi zdaji zatim jeste slozitejsi, tak jsem to zaitm vynechal. V principu jde o to, ze nejakym zpusobem budu potrebovat nakonec ten ES zalohovat/obnovovat, takze snapshot, nebo dump.
DIky