Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: OSB 1.9.0 Docker Image fails when mounting file #636

Closed
IanHoang opened this issue Sep 11, 2024 · 2 comments
Closed

[Bug]: OSB 1.9.0 Docker Image fails when mounting file #636

IanHoang opened this issue Sep 11, 2024 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@IanHoang
Copy link
Collaborator

IanHoang commented Sep 11, 2024

Describe the bug

When users attempt to mount a file to OSB 1.9.0 Docker Image, it fails with a permissions error

sudo docker run -v ./home/benchmark.ini:/opensearch-benchmark/.benchmark/benchmark.ini opensearchproject/opensearch-benchmark:1.9.0 execute-test --target-hosts https://search-hoangia-test-ee-btik57xti77rhypkon4pourlfe.us-east-1.es.amazonaws.com/ --client-options=basic_auth_user:'xxxxx',basic_auth_password:'xxxxx' --pipeline benchmark-only --kill-running-processes --workload percolator --workload-params '{"number_of_shards":"1","number_of_replicas":"0"}'

   ____                  _____                      __       ____                  __                         __
  / __ \____  ___  ____ / ___/___  ____ ___________/ /_     / __ )___  ____  _____/ /_  ____ ___  ____ ______/ /__
 / / / / __ \/ _ \/ __ \\__ \/ _ \/ __ `/ ___/ ___/ __ \   / __  / _ \/ __ \/ ___/ __ \/ __ `__ \/ __ `/ ___/ //_/
/ /_/ / /_/ /  __/ / / /__/ /  __/ /_/ / /  / /__/ / / /  / /_/ /  __/ / / / /__/ / / / / / / / / /_/ / /  / ,<
\____/ .___/\___/_/ /_/____/\___/\__,_/_/   \___/_/ /_/  /_____/\___/_/ /_/\___/_/ /_/_/ /_/ /_/\__,_/_/  /_/|_|
    /_/

[INFO] [Test Execution ID]: 6dd46fcf-76c7-44cd-bff5-4e73b859d01f
[INFO] You did not provide an explicit timeout in the client options. Assuming default of 10 seconds.
[ERROR] Cannot execute-test. Error in test execution orchestrator ([Errno 13] Permission denied: 'workloads')

Confirmed that error not present in previous versions.

Culprit

When you run the command, the docker container spawns and then closes because of the early failure. To discover the permissions issues, run the docker run command and afterwards have another window that runs export ID=$(sudo docker ps --no-trunc | awk 'NR==2 {print $1}') && sudo docker exec -it $ID ls -lrt /. Did this with OS 1.5.0, 1.8.0, and 1.9.0 Docker Images and the culprit seems to be related to ownership.

# OS 1.5.0 
$ export ID=$(sudo docker ps --no-trunc | awk 'NR==2 {print $1}') && sudo docker exec -it $ID ls -lrt /
drwxr-xr-x.   1 benchmark opensearch-benchmark    41 Sep 11 18:29 opensearch-benchmark

# OS 1.8.0
$ export ID=$(sudo docker ps --no-trunc | awk 'NR==2 {print $1}') && sudo docker exec -it $ID ls -lrt /
total 16
...
drwxr-xr-x.   1 benchmark opensearch-benchmark    41 Sep 11 18:20 opensearch-benchmark

# OS 1.9.0
$ export ID=$(sudo docker ps --no-trunc | awk 'NR==2 {print $1}') && sudo docker exec -it $ID ls -lrt /
total 16
...
drwxr-xr-x.   1 root root    24 Aug 22 16:18 opensearch-benchmark
...

To reproduce

  1. Create a directory and run chmod -R 777.
  2. Create a benchmark.ini within the directory and populate it
  3. Run the command
sudo docker run -v <BENCHMARK.INI PATH>:/opensearch-benchmark/.benchmark/benchmark.ini opensearchproject/opensearch-benchmark:1.9.0 execute-test --target-hosts <ENDPOINT> --client-options=basic_auth_user:'xxxxx',basic_auth_password:'xxxxx' --pipeline benchmark-only --kill-running-processes --workload percolator --workload-params '{"number_of_shards":"1","number_of_replicas":"0"}'

Expected behavior

When users run the same command but for OSB 1.5.0 and 1.8.0 Docker Images, it works.

Screenshots

No response

Host / Environment

  • OS: Amazon Linux 2

Additional context

No response

Relevant log output

No response

@IanHoang IanHoang added bug Something isn't working untriaged and removed untriaged labels Sep 11, 2024
@gkamat gkamat self-assigned this Sep 12, 2024
@gkamat gkamat moved this from 🆕 New to 🏗 In progress in Engineering Effectiveness Board Sep 12, 2024
@IanHoang
Copy link
Collaborator Author

We'll aim to fix this in a patch release

@gkamat gkamat moved this from 🏗 In progress to 👀 In review in Engineering Effectiveness Board Sep 12, 2024
@gkamat gkamat moved this to 🏗 In progress in OpenSearch Benchmark Roadmap Sep 13, 2024
@gkamat gkamat moved this from 🏗 In progress to 👀 In Review in OpenSearch Benchmark Roadmap Sep 13, 2024
@gkamat
Copy link
Collaborator

gkamat commented Sep 13, 2024

Fixed with #643.

@gkamat gkamat closed this as completed Sep 13, 2024
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Engineering Effectiveness Board Sep 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: ✅ Done
Development

No branches or pull requests

2 participants