MLH-Fellowship / cinder-benchmarks

Cinder is Meta's internal performance-oriented production version of CPython.
https://trycinder.com
Other
0 stars 0 forks source link

Setting Up the Benchmark Runner for Cinder on an AWS Instance #9

Open MAMV3x3 opened 11 months ago

MAMV3x3 commented 11 months ago

Steps Taken:

  1. Repository Initialization:
    • Created a new empty repository on GitHub named cinder_bench_runner.
    • Cloned the repository locally.
    • Added bench_runner from a specific Git tag to requirements.txt.
  2. Environment Setup:
    • Created a virtual environment using python -m venv venv.
    • Populated the requirements.txt with git+https://github.com/faster-cpython/bench_runner@v0.2.2#egg=bench_runner.
    • Activated the virtual environment and installed the required packages from requirements.txt.
  3. Initial Benchmarking Setup:
    • Tried running python -m bench_runner.scripts.install but encountered an AssertionError (#8).
    • Realized the need for a GitHub Actions self-hosted runner setup before proceeding.
  4. AWS EC2 Instance Creation:
    • Initially set up an Amazon Linux 2023 instance but faced some compatibility issues.
    • Decided to set up a new instance using Ubuntu for compatibility.
  5. Setting Up GitHub Actions Runner on EC2:
    • SSH'd into the EC2 instance.
    • Downloaded and extracted the GitHub Actions runner.
    • Configured the runner for the cinder_bench_runner repository following the self-hosted runner documentation.
    • Added necessary labels such as self-hosted, Linux, X64, bare-metal, and linux-x64-ec2runner to the runner.
    • Set up the runner as a service to ensure it starts automatically on boot.
      • Add the runner as a service:
        • sudo ./svc.sh install
        • sudo ./svc.sh start
      • Verify the runner's status:
        • sudo ./svc.sh status
      • (Optional) If you want to stop or remove the service in the future:
        • sudo ./svc.sh stop
        • sudo ./svc.sh uninstall
  6. Re-attempting Benchmarking Setup:
    • In response to the issue raised in #8, I created a runners.ini file at the root of the repository. The exact configuration can be viewed here.
    • Successfully executed python -m bench_runner.scripts.install.
    • This step created necessary configuration files like README.md, bases.txt and benchmarks.manifest.

For an in-depth view of the setup and configuration, please refer to the bench_runner repository: cinder_bench_runner.

Closes #8