-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
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
Comments
Hi @sagarkalankar1 -Thank you for bringing this issue to our attention. We will update you on this issue after investigating. |
I'm facing a similar issue with an android build that was working fine last week. Now it fails with |
Hi @sagarkalankar1 - You can try the following strategies to free up space and optimize your pipeline: A. Clean Up Unnecessary Directories and Files
|
The issue seems to be with the ubuntu-latest image since the pipeline works if I run on an mac-os image and it was working before the latest update. Was working: Is failing: |
We are running into a similar issue - we run elasticsearch in docker that we use in our test suite, and we get an error |
same probleme for me
i just run clean action before with this script
any solution please ? |
@alainib @danibonilha @mantljosh - By this week, new image version will be rolled out. So, kindly try once after new image version rolled out.
Explanation:- The script cleans up various large directories (/usr/local/.ghcup, /opt/hostedtoolcache/CodeQL, /usr/local/lib/android/sdk/ndk, /usr/share/dotnet, /opt/ghc, /usr/local/share/boost) to free up space. Similar cleanup steps are performed after the build to ensure any temporary files created during the build process are removed. By this approach, you should be able to manage disk space more effectively and prevent build failures due to insufficient disk space. |
@Prabhatkumar59 wow thank you for fast answer and response :) i will try it . what is the best approach please ?
i'm not sure if multiples yml file share folders like in macos/linux etc or each one have it's one space like in docker and running cleanup yml file whould not affect my reel yml file . thanks |
FWIW we changed |
Hi @alainib - Here are the best approaches which I am providing you to handle the disk space issue effectively: Approach 1: Add Cleanup Steps to the Failing YAML File Updated YAML File Example:
This approach 1 ensures that cleanup is performed before every build, preventing disk space issues from affecting the build process. Approach 2: Create a Separate Cleanup YAML File You can try to create a separate YAML file dedicated to disk space cleanup. This approach allows you to trigger the cleanup workflow manually or on a schedule, without cluttering the main build YAML file. Cleanup YAML File Example:
Main Build YAML File (Simplified) which is as follows:-
This approach 2 provides flexibility, allowing you to trigger cleanup manually or on a schedule. This keeps the main build YAML file clean and focused. So, by using the the above approaches, you will able to fix those issues. |
@sagarkalankar1 - I hope this issue is resolved and we are closing this issue. Feel free to reach out to us...thanks |
I'm still experiencing the same issue, even with the (seemingly) new image:
|
The cleanup procedure from above raises free space from 16 to 36Gb. |
I cannot do any clean-up steps since the role of the runner image is simply to load another linux's docker container. The free space seems to have gotten lower in the last 6 to 12 months from about 26GB down to 19GB at the moment. It was 21GB 3 weeks ago. I have a Switching from ubuntu-latest (22.04) to ubuntu-24.04 explicitly, gives me an extra 10GB from 19GB back to 30GB. I am wondering if the |
I am doing
so any clean-up of ubuntu can't be done. |
getting this issue on the m1 Mac runners as well. Only started a few hours ago. There have been no changes on our end. Our jobs just randomly started failing because of this issue. |
Also seeing this in Firebase builds on the macos-14 runner starting Friday, August 30, on otherwise unchanged configurations - https://github.com/firebase/firebase-ios-sdk/actions/runs/10626580586 |
works! |
I have the similar problems. Why not increase the disk size of action runner to about 50G free. |
@Prabhatkumar59 Hi, I didn't understand your approach 2, when the main build job trigger cleanup job? I didn't find the connection between them. Could you explain more in details. |
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
Runner images affected
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.
The text was updated successfully, but these errors were encountered: