Error: spawn ENOMEM

1,081 views
Skip to first unread message

Steven Keller

unread,
Jun 11, 2014, 1:07:01 PM6/11/14
to node...@googlegroups.com
I have a nodered flow that runs for 6 to 10 hours before it crashes with Error: spawn ENOMEM
Does anyone have any suggestions on what to look for that might be using up all the memory? 

I have some Exec nodes that get called every 5 seconds or so but none of them use spawn.

In some Function nodes I create new buffers at times.  Do they automatically get cleared from memory when the function is done?  Do I need to clean them up?

I am coming from the .NET world so I am still getting to know the node.js world.

Thanks,

Nicholas O'Leary

unread,
Jun 11, 2014, 2:07:25 PM6/11/14
to node...@googlegroups.com

What platform are you running on?

By default node.js won't start doing much garbage collection until it hits 512mb in memory. On small platforms, such as the raspberry pi, that's all you've got. If you look at our docs for running on the Pi, there are the command line args needed to get node.js garbage collect at a lower limit.

N

--
http://nodered.org
---
You received this message because you are subscribed to the Google Groups "Node-RED" group.
To unsubscribe from this group and stop receiving emails from it, send an email to node-red+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Steven Keller

unread,
Jun 11, 2014, 2:12:03 PM6/11/14
to node...@googlegroups.com
I am running on a SABRE Lite from Boundary Devices (http://boundarydevices.com/products/sabre-lite-imx6-sbc/)
It has 1GB RAM.  I will try a few different values for --max-old-space-size and see what happens.

Thanks 

Steven Keller

unread,
Jun 13, 2014, 12:44:22 AM6/13/14
to node...@googlegroups.com
 
I set the --max-old-space-size =256.  That seems to have solved the problem.  Memory usage is holding at 34% for the last 24+ hours.  We will see how it goes over the weekend.

Thanks! 
Reply all
Reply to author
Forward
0 new messages