-
Notifications
You must be signed in to change notification settings - Fork 694
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
IOError: [Errno 12] Cannot allocate memory #520
Comments
Thanks for reporting this issue! I do think that probably rules_docker could be pushed to the point where it exhaust resources if it was ran inside a container, but not sure what you would need to do to get there (maybe if you could describe a bit the type of image you are trying to build inside the container?) |
I am running into errors in a similar vein in our CI:
I have also had it error with: We do have a bundle of 12 images that are being built in a docker container, is there are recommended strategy for limiting the resource usage of |
As far as I have found in the bazel docs, the flags for controlling resource usage are: I'm going to try fiddling around with them and see if I can get the build to work. |
Running with bazel build --jobs=1 fixed the issue on circle-ci running within a docker executor. |
@enriched I guess the only problem with |
@Globegitter I ended up bumping up the I don't understand how the Bazel scheduler estimates the amount resources an action is going to use, but it seems like it is underestimating some of the docker rules. |
This issue has been automatically marked as stale because it has not had any activity for 180 days. It will be closed if no further activity occurs in 30 days. |
This issue was automatically closed because it went 30 days without a reply since it was labeled "Can Close?" |
Just seen this error in our ci:
This is the first time we are seeing this error after having used this setup for a few weeks now without any issues.
About our setup:
We are running in circleci within a docker container. I wonder if it means that we ran out of memory within the build container? We have seen in the past times where bazel got killed due to using more memory than the build container was limited to and since setting
startup --host_jvm_args=-Xmx3G
as well asbuild:ci --local_resources=3072,2.0,1.0
the problem was resolved. Not sure if that is in any way related and if there is anything that can be done here in these rules, but thought it is worth posting, even if it is just other people running into this issue.The text was updated successfully, but these errors were encountered: