Skip to content

Remove node certs before creating new ones#112

Closed
NickDris wants to merge 1 commit into
elastic:masterfrom
NickDris:remove-certs-when-reinstall
Closed

Remove node certs before creating new ones#112
NickDris wants to merge 1 commit into
elastic:masterfrom
NickDris:remove-certs-when-reinstall

Conversation

@NickDris

Copy link
Copy Markdown
Contributor

During ES installation (esrally install) elasticsearch-certutil writes to {install_root}/node-cert.zip. If the installation path is preserved using preserve_elasticsearch_install=True a second esrally install with car overrides results in "exit code 74: output file already exists"

That is because

  1. At the 2nd pass rally extracts the ES tarball with the ElasticsearchInstaller.install() but install_dir already exists with the old node-cert.zip from 1st benchmark.
  2. delete_pre_bundled_configuration() only deletes the config/ subdirectory.
  3. A 2nd execution of elasticsearch-certutil cert --out="{install_root}/node-cert.zip" after the post installation hook results to file already exists → exit code 74.

This was revealed when trying to execute sequential benchmark experiments with ES reinstallation using different cluster settings per experiment and preserve the elasticsearch directory during the benchmark executions.
Before that, I was running all experiments using identical install parameters, so the preserved installation was functionally fine.

This aims to clean the certs directory before extracting.

@NickDris NickDris requested a review from a team April 24, 2026 14:42
@gareth-ellis

Copy link
Copy Markdown
Member

Should we be trying to install over the top of an existing installation?

@NickDris

NickDris commented Apr 24, 2026

Copy link
Copy Markdown
Contributor Author

Should we be trying to install over the top of an existing installation?

Only after esrally stop I think yes? Do you mean we should be using different installation id?

@gareth-ellis

Copy link
Copy Markdown
Member

I would say so yes, we should use a new installation id - im surprised we dont alert earlier though that the installation already exists

@NickDris

NickDris commented May 1, 2026

Copy link
Copy Markdown
Contributor Author

We have decided to use another strategy for this. Rally users should be creating another build installation path, provided that different car params are used. This is cleaner and more efficient.

@NickDris NickDris closed this May 1, 2026
@NickDris NickDris deleted the remove-certs-when-reinstall branch May 4, 2026 11:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants