-
Notifications
You must be signed in to change notification settings - Fork 15k
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
How to increase electron max memory limit (--max_old_space_size) #2056
Comments
Does |
Sorry but it does not work. I tried: It work correctly for a pure nodejs program with following command: |
The option --js-flags="--max_old_space_size=4096" works on electron build from source following instructions: http://electron.atom.io/docs/v0.28.0/development/build-instructions-mac. I run with following command: My config: From my point of view, you can close this issue. Thank you. |
👍 |
Sorry to revive an old thread, but it looks like |
@zcbenz Can you comment on the differences how this flag behaves when having
but when running it like so it is ignored
Using the latter variant with nodejs (8.0.0) is working and shows the desired effect. What is different in electron? |
I got it to work like this by inserting this piece of code in Browser.js before ready event:
|
Hello could you address location of that file? I found several Browser.js |
In win10, electron 2.0.13, but you can add
Or if you use electron-vue, change two part:
|
Hi, |
Hi I am using electron 23.1.1 and I facing an Out Of Memory error can be please address me how can I resolve the same |
Is it possible to use the V8 option --max_old_space_size=N to increase the max memory limit of the electron process and its BrowserWindow subprocess ?
I tried different commands without success (I am on Mac OS X with node installed with Homebrew and electron installed with npm):
$ electron --max_old_space_size=4096 app/
$ node --max_old_space_size=4096 ~/.brew/bin/electron app/
...
(I also tried --max_old_space_size and --max-old-space-size).
I reach the limit around 1.5~1.7Go of memory when the following error occurs:
[1765:0625/153220:ERROR:atom_bindings.cc(32)] Fatal error in V8: CALL_AND_RETRY_LAST Allocation failed - process out of memory
I am brute testing with following main.js program:
Regards,
Bruno.
The text was updated successfully, but these errors were encountered: