Skip to content

You are running out of disk space. The runner will stop working when the machine runs out of disk space. Free space left: 72 MB. How to fix this ? #10386

@sagarkalankar1

Description

@sagarkalankar1

Description

  • I am using 'ubuntu-latest' as github runner for my pipeline.

  • My GitHub Actions pipeline defines a workflow for building and publishing an Android project to Firebase App Distribution.

  • My pipeline sometimes given warning - "You are running out of disk space. The runner will stop working when the machine runs out of disk space. Free space left: 72 MB" and pipeline fails.

  • Seeing other github issues similar to this one, I found and tried a workaround as below:-

sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf "/usr/local/share/boost"
sudo rm -rf "$AGENT_TOOLSDIRECTORY"

But above folders does not exist when I tried viewing folders on my github runner 'ubuntu-latest'.

I can see below files and folders:-
36G /usr
23G /usr/local
13G /usr/local/lib
12G /usr/local/lib/android/sdk
12G /usr/local/lib/android
12G /opt
8.5G /opt/hostedtoolcache
7.8G /usr/local/lib/android/sdk/ndk
6.7G /usr/lib
5.6G /usr/share
5.5G /usr/local/.ghcup/ghc
5.5G /usr/local/.ghcup
5.0G /opt/hostedtoolcache/CodeQL/2.18.1/x64/codeql
5.0G /opt/hostedtoolcache/CodeQL/2.18.1/x64
5.0G /opt/hostedtoolcache/CodeQL/2.18.1
5.0G /opt/hostedtoolcache/CodeQL
3.1G /swapfile
3.0G /opt/hostedtoolcache/CodeQL/2.18.1/x64/codeql/swift
2.8G /usr/local/.ghcup/ghc/9.10.1

What can I do for this issue ?

Platforms affected

  • Azure DevOps
  • GitHub Actions - Standard Runners
  • GitHub Actions - Larger Runners

Runner images affected

  • Ubuntu 20.04
  • Ubuntu 22.04
  • Ubuntu 24.04
  • macOS 12
  • macOS 13
  • macOS 13 Arm64
  • macOS 14
  • macOS 14 Arm64
  • Windows Server 2019
  • Windows Server 2022

Image version and build link

Runner version: '2.317.0'

Is it regression?

It is occuring randomly.

Expected behavior

It should not give this warning and build should be completed successfully and build should not fail due to disk space issue.

Actual behavior

My pipeline sometimes gives warning - "You are running out of disk space. The runner will stop working when the machine runs out of disk space. Free space left: 72 MB" and pipeline fails.

Repro steps

This issue comes due to disk space issue of github runner.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions