Up until now I have only used my imac and my macbook to work on my app and had very few issues. I now want to be able to use my Windows pc as well but after 2 days of messing around, I just can't get my app to run. I can create a new app and it runs fine.
I have installed Meteor with Chocolatey as instructed, with no issues.
I then pulled my app from the git repo, ran npm install, and then meteor run. All goes well until the 'Linking' phase where it shows up with this error...
C:\Users\Me\Desktop\myapp>meteor --settings settings-development.json
[[[[[ C:\Users\Me\Desktop\myapp]]]]]
=> Started proxy.
=> A patch (Meteor 1.5.4.2) for your current release is available!
Update this project now with 'meteor update --patch'.
Linking -
<--- Last few GCs --->
58416 ms: Mark-sweep 678.5 (734.8) -> 678.5 (734.8) MB, 309.8 / 0 ms [allocation failure] [scavenge might not succeed].
58824 ms: Mark-sweep 678.5 (734.8) -> 689.2 (734.8) MB, 407.8 / 0 ms [allocation failure] [scavenge might not succeed].
59177 ms: Mark-sweep 689.2 (734.8) -> 689.0 (734.8) MB, 353.2 / 0 ms [last resort gc].
59528 ms: Mark-sweep 689.0 (734.8) -> 689.2 (734.8) MB, 351.0 / 0 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 37E25599 <JS Object>
1: JSONSerialize(aka JSONSerialize) [native json.js:~120] [pc=0DA21153] (this=37E08099 <undefined>,G=37E6D451 <String[4]: data>,j=09243DF1 <an Object with map 2D019699>,v=09243E49 <JS Function replacer (SharedFunctionInfo 2350ECD1)>,w=09243EC9 <JS Array[2]>,x=37E08365 <String[0]: >,y=37E08365 <String[0]: >)
2: SerializeObject(aka SerializeObject) [native json.js:97] [pc=0DA23534] (this=37E080...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory
C:\Users\Me\Desktop\myapp>
Obviously it is related to running out of memory. What I have gathered from many articles/threads etc. is that I need to set the TOOL_NODE_FLAGS="--max-old-space-size=4096".
For some reason though, after I run set TOOL_NODE_FLAGS="--max-old-space-size=4096", I am no longer able to run 'meteor run'. the command prompt thinks for a second, and then nothing happens...
So if I run C:\Users\Me\Desktop\myapp>meteor --settings settings-development.json, I get the error above.
If I run C:\Users\Serks\Desktop\cakenote>set TOOL_NODE_FLAGS="--max-old-space-size=4096" and then run C:\Users\Me\Desktop\myapp>meteor --settings settings-development.json, nothing happens and the cursor returns to...C:\Users\Serks\Desktop\cakenote.
Does anyone know how I can get meteor to start with more memory on Windows 10 through cmd line?
Thanks in advance.
I don’t think this option worked in meteor 1.5
Please see this thread
https://forums.meteor.com/t/meteor-wont-start-with-max-old-space-size-solved/44745
Related
While building Angular 4 application with the command:
ng build --prod
I am receiving the error message: "FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory"
The full error message is:
92% chunk asset optimization
<--- Last few GCs --->
118862 ms: Mark-sweep 636.4 (717.1) -> 636.0 (717.1) MB, 949.7 / 0.0 ms [allocation failure] [GC in old space requested].
119770 ms: Mark-sweep 636.0 (717.1) -> 636.0 (717.1) MB, 908.3 / 0.0 ms [allocation failure] [GC in old space requested].
120673 ms: Mark-sweep 636.0 (717.1) -> 639.2 (705.1) MB, 902.1 / 0.0 ms [lastresort gc].
121592 ms: Mark-sweep 639.2 (705.1) -> 643.0 (705.1) MB, 919.1 / 0.0 ms [lastresort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 0427B80D <JS Object>
1: reduce_vars [042081D9 <undefined>:~8085] [pc=33877059] (this=0D827DD5 <an AST_SymbolRef with map 127AC9C9>,tw=2A3BE0B1 <a TreeWalker with map 12716AED>,descend=0C1795B5 <JS Function noop (SharedFunctionInfo 08B51CAD)>,compressor=1066
FAE5 <a Compressor with map 117D74D1>)
2: visit [042081D9 <undefined>:~8175] [pc=376ADA83] (this=2A3BE0B1 <a TreeWalker with map 12716AED>,node=0D827DD5 <an AS...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
This application has been built before many times with no problems. Only today have I started getting this error. No updates to node.js have been done since the last time the app has been built.
Node.js version is 6.11.0
Many people say it can be the memory allocation issue. I have tried this suggestion but it did not fix the issue.
After digging through many web pages with people having similar issues, I tried the following:
ng build --prod --aot false
and it worked. aot stands for ahead-of-time compilation in this case I believe. I still have no clue why this fix worked but it did.
I have a admin portal where all the documents from database are configured and manipulated.
We have a collection for language translation which contains a lot of document.
And admin can modify all this document.
If admin opens any other collection it works fine. But when he opens this language translation collection the systems gets slower and after few mins I found this error.
<--- Last few GCs --->
513530251 ms: Mark-sweep 1397.7 (1458.0) -> 1397.7 (1458.0) MB, 2719.4 / 2 ms [allocation failure] [
GC in old space requested].
513533054 ms: Mark-sweep 1397.7 (1458.0) -> 1397.7 (1458.0) MB, 2802.9 / 2 ms [last resort gc].
513535773 ms: Mark-sweep 1397.7 (1458.0) -> 1397.6 (1458.0) MB, 2718.9 / 2 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 000002D0BF1B4639 <JS Object>
1: new constructor(aka WritableState) [_stream_writable.js:88] [pc=0000036F0D0CA7F9] (this=00000
153740AD191 <a WritableState with map 0000017D64825C01>,options=00000065E299D0F1 ,stream=00000153740ACFA1 )
3: Writable [_stream_writable.js:143] [pc=0000036F0D0CA0C2] (this=00000153740ACFA1 <a Socket with map 0000017D...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory
Can anyone help me what can solve this issue???
I start my node with the following syntax.
set node_debug=foo&& node --max-old-space-size=8192 server.js
I had the same problem with Node installed through Homebrew.
Try to run vim `which npm`
and change:
#!/usr/bin/env node
to:
#!/usr/bin/env node --max-old-space-size=2048
Update: By the way, I have fixed this error by following these simple steps
Add an environment variable:
TOOL_NODE_FLAGS="--max-old-space-size=4096"
CircleCI is timing out while running eslint using node.
I get the following error message:
command ... took more than 10 minutes since last output
On my local machine, it only takes 17 seconds.
(Answer below...)
I logged into CircleCI using "Debug via SSH". I confirmed that eslint was hanging. Then, I figured out how to get more debugging information:
DEBUG=eslint:cli-engine eslint .
After a long time, Node actually crashed:
<--- Last few GCs --->
345472 ms: Scavenge 1399.8 (1457.3) -> 1399.8 (1457.3) MB, 38.0 / 0 ms (+ 6.8 ms in 1 steps since last GC) [allocation failure] [incremental marking delaying mark-sweep].
348177 ms: Mark-sweep 1399.8 (1457.3) -> 1399.8 (1457.3) MB, 2705.8 / 0 ms (+ 8.7 ms in 2 steps since start of marking, biggest step 6.8 ms) [last resort gc].
350927 ms: Mark-sweep 1399.8 (1457.3) -> 1399.5 (1457.3) MB, 2749.7 / 0 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 0xd2a8c0b4629 <JS Object>
1: /* anonymous */ [/home/ubuntu/website-django/static/node_modules/babel-eslint/babylon-to-espree/toToken.js:~1] [pc=0x33a525e2adb9] (this=0x1e91da709851 <JS Global Object>,token=0x349f83a2fc01 <a Token with map 0x3b6a9d8c2e31>,tt=0x2c0cfbd85ee1 <an Object with map 0x3b6a9d898959>,source=0x3314aa504101 <Very long string[1177579]>)
2: toTokens [/home/ubuntu/website-django/static/node_mod...
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory
Aborted (core dumped)
Finally, I realized that it was trying to lint my build directory which contained a bunch of third-party libraries, including Highchart, which are known to cause eslint problems because they're so big.
I added this to my .eslintignore:
build/**
Then, the problem went away.
The take home message is: make sure you're only linting the things you need to lint.
I'm struggling with the following issue.
I had created some e2e tests, which they passes successfully when I run them locally, with locally I mean, when I run tests by starting the application up, using an NPM script thats uses the grunt task like this:
package.json:
"e2e-local": "scripts/test-e2e.sh local"
test-e2e.sh
#!/bin/bash -ex
grunt test:e2e:"$1" --tags "$2"
But when I run my test using BrowserStack's selenium server or my own... I'm getting:
<--- Last few GCs --->
1221269 ms: Mark-sweep 1372.9 (1435.0) -> 1372.8 (1435.0) MB, 675.7 / 0 ms [allocation failure] [GC in old space requested].
1222093 ms: Mark-sweep 1372.8 (1435.0) -> 1372.8 (1435.0) MB, 722.6 / 0 ms [allocation failure] [GC in old space requested].
1222832 ms: Mark-sweep 1372.8 (1435.0) -> 1372.8 (1435.0) MB, 738.8 / 0 ms [last resort gc].
1223560 ms: Mark-sweep 1372.8 (1435.0) -> 1372.8 (1435.0) MB, 727.9 / 0 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 0x2903647c9fa9 <JS Object>
2: encode64s [/Users/brunosoko/OLAPIC/LemuramaModsquad/node_modules/gherkin/lib/gherkin/formatter/json_formatter.js:~126] [pc=0x25cdf0f7939] (this=0x2903647e99d9 <JS Global Object>,input=0x24ffe942e499 <Very long string[5816704]>)
3: embedding [/Users/brunosoko/OLAPIC/LemuramaModsquad/node_modules/gherkin/lib/gherkin/formatter/json_formatter.js:58] [pc=0x25cdedec016] (this=0x10ab271a84f...
FATALAbort trap: 6
I would appreciate any though about this! I had tried what states in this post as well but nothing!
Is there a way to get a longer stacktrace when node runs into an out of memory error?
<--- Last few GCs --->
39984 ms: Scavenge 594.7 (636.8) -> 594.7 (637.8) MB, 0.5 / 0 ms (+ 0.0 ms in 1 steps since last GC) [allocation failure] [incremental marking delaying mark-sweep].
40058 ms: Mark-sweep 594.7 (637.8) -> 382.8 (411.8) MB, 73.7 / 0 ms (+ 32.0 ms in 5 steps since start of marking, biggest step 32.0 ms) [last resort gc].
40096 ms: Mark-sweep 382.8 (411.8) -> 382.5 (409.8) MB, 38.0 / 0 ms [last resort gc].
<--- JS stacktrace --->
==== JS stack trace =========================================
Security context: 07985C51 <JS Object>
1: Join(aka Join) [native array.js:158] [pc=2CE5D269] (this=079080C9 <undefined>,p=351F00A9 <JS Array[34]>,v=34,C=249FA8A5 <String[1]: ,>,B=07976BD1 <JS Function ConvertToString (SharedFunctionInfo 07945515)>)
2: InnerArrayJoin(aka InnerArrayJoin) [native array.js:335] [pc=2CE5C475] (this=079080C9 <undefined>,C=249FA8A5 <String[1]: ,>,p=351F00A9 <JS Array[34]>,v=34)
3: join [native array....
FATAL ERROR: CALL_AND_RETRY_LAST Allocation failed - process out of memory
Only three lines of the stack trace are shown. Is there a way to get more information on what was happening right before the error?
I've tried these node flags which didn't seem to help in this situation.
--trace_track_allocation_sites
--stack_trace_limit=40
--builtins_in_stack_traces
--stack_trace_on_illegal
In my case after a database error is received and handled (bad sql, not what I'm concerned with), about 30 seconds later I get an out of memory error. As far as I can tell my application isn't doing anything in these 30 seconds. There are no additional calls from client to server (every call is written to console) and when I run it through the debugger, after the last step over, 30 seconds pass without the debugger breaking on any line (either if I wait or if I click pause).
The above is from Node 5.5.0. The error happens in 0.12.9 but that version doesn't produce any stack trace. Node 4.2.6 give the same three-level stack trace.