question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Download speed on self-hosted runners is significantly slower

See original GitHub issue

👋🏼

We’ve started working with self-hosted runners, but noticed that the download speed when downloading the cache is significantly slower than on hosted runners. Here’s the breakdown of what is happening:

  • Self-hosted runner version: 2.296.2
  • Cache size: ~300MB
  • Average download speed
    • Hosted runners: 50 MBs/s
    • Self-hosted runners: 3.5 MBs/s

Hosted:

Screenshot 2022-09-19 at 18 34 01

Self-hosted:

Screenshot 2022-09-19 at 18 33 38

Workflow:

      - name: Cache yarn dependencies
        uses: actions/cache@v3
        id: cache-dependencies
        with:
          path: node_modules
          key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
          restore-keys: |
            ${{ runner.os }}-yarn-

      - name: Install dependencies
        if: steps.cache-dependencies.outputs.cache-hit != 'true'
        run: |
          yarn install --frozen-lockfile

I’m pretty confident there’s no limitation on our machine, and I’m not sure if this is a limitation on the runner itself, but at that speed installing dependencies takes practically the same time as pulling the cache.

Thanks in advance!

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:1
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
klaus993commented, Sep 29, 2022

I’m having the same issue (10 MB/s in self-hosted, 100 MB/s in GitHub hosted runners), and I’m wondering: why isn’t the cache hosted locally (in the runner) so there is no need for internet transfer? Where exactly is it hosted?

0reactions
omairvaiyanicommented, Dec 2, 2022

We moved to Self-Hosted Runners to reduce our build times with custom AMIs and bigger instances, but our efforts are being hindered by extremely slow cache download and post-job upload steps. What takes just 10-20 seconds on the GitHub hosted runner sometimes takes up to 15 minutes on our Self-Hosted runners.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Add support for fast caching on github self-hosted runners ...
In the places we have adopted Wireit, it seems significantly faster to use GitHub Actions Caching than to run the build script itself....
Read more >
Upload speed for self-hosted site isn't so fast - Reddit
When I download a file I am running over a tunnel (fast public IP box, not over CloudFlare), on a fast connected remote...
Read more >
If your Self Hosted IR is running Slow what steps ... - YouTube
If your Self Hosted IR is running Slow what steps you will take in Azure Data Factory | ADF Interview Questions 2022, In...
Read more >
Why GitHub Actions is so slow - BuildJet
In this breakdown we will take a close look at why GitHub Actions default runners are so slow. Firstly, we'll compare GitHub Actions...
Read more >
Set up your own GitHub runner to increase build performance
Here you can create a self-hosted runner for your organization. ... Every build was ~50% slower than when running only one build.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found