Skip to content

JavaScript heap out of memory #3099

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

Closed
ishara opened this issue Nov 10, 2016 · 4 comments
Closed

JavaScript heap out of memory #3099

ishara opened this issue Nov 10, 2016 · 4 comments

Comments

@ishara
Copy link

ishara commented Nov 10, 2016

Please provide us with the following information:

OS?

Windows 10.

Versions.

angular-cli: 1.0.0-beta.19
node: 6.6.0
os: win32 x64

Repro steps.

This is big project

The log given by the failure.

FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory

.

How can I set Heap size in ng


Thanks! We'll be in touch soon.

@celliott181
Copy link
Contributor

celliott181 commented Nov 10, 2016

For others also seeking help with this, the issue is known to plague the CLI (#1652, #2974) when projects grow beyond what many of us consider small-medium sized codebases.

As you mentioned, the fix it to set Node's heap size. This is done with node --max_old_space_size=[Space in MB] followed by whatever call you wanted to make, e.g. node --max_old_space_size=2048 ./node_modules/.bin/ng build (Credit to @hansl for that one line.)

@naveedahmed1
Copy link

This should help #1652 (comment)

@filipesilva
Copy link
Contributor

Closing as dupe of #1652

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants