CircleCI Crashes on Ubuntu instances due to Memory Usage
See original GitHub issueAsk your Question
The CircleCI boxes that are used for ubuntu testing (specifically our android build) have 36 cores. When we are running our yarn bundle --platform=android
build, we are running out of memory with this error:
./node_modules/react-native/Libraries/Utilities/stringifySafe.js
Module build failed (from ./node_modules/haul/node_modules/thread-loader/dist/cjs.js):
Thread Loader (Worker 32)
ENOMEM: not enough memory, read
We don’t see this problem on our other workstations, that have 8 cores.
When we modified the thread-loader
options to only have 1 worker
, we no longer see this issue.
How do you recommend that we modify the configuration to have less thread-workers? What strategies do people normally use to merge in webpack config settings? webpack-merge
?
Currently we are doing this:
export default {
webpack: env => {
const config = createWebpackConfig({
entry: `./index.js`
})(env)
config.module.rules[1].use[1].options.workers = 1
// A bunch of other rules and settings
}
}
But this is obviously sub-optimal.
Thanks for looking and helping!
James
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (6 by maintainers)
Top Results From Across the Web
Workflow stops/crashes seemingly randomly - CircleCI Discuss
I'm experiencing that the automated test runs we run on PRs sometimes fails/crashes. To me it seems the docker instance just kills itself ......
Read more >Exit Code 137 - Out of Memory – CircleCI Support Center
This is a Linux error code which you may see on CircleCI when your container runs out of memory. Containers are given 4GB...
Read more >Containers running out of memory on 14.04 image but runs ...
Using Ubuntu some containers run out of memory with capybara-webkit and rspec showing taking all of the memory. The error message is Your ......
Read more >Builds died unexpectedly - Build Environment - CircleCI Discuss
We have taken a snapshot of the memory usage at the time, which you can find in a build artifact named `memory-usage.txt`.
Read more >CircleCI Release Notes
Server v4.x makes improved use of Kubernetes secrets and removes the requirement to ... that was causing pods to crash as a result...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yeah, I can submit a pull request. Much friendlier than manipulating nested JavaScript objects…
I seem to recall reading something about Webpack having memory leaks. Which version are you using? Could you try upgrading and see if that helps?