DEV Community


Node JS Memory Limits

jordanfinners profile image Jordan Finneran Originally published at Updated on ・1 min read

Recently came across an issue at work where one of our Node JS micro services kept hitting the default memory limit on Node JS.

It was moving GB of data around at the time and kept hitting the default of ~1.7GB of memory and causing the process manager to restart it.

So thought I’d share the command line argument to set the memory size to what you like max_old_space_size=4096 as you might find it handy!

Discussion (0)

Forem Open with the Forem app