How to solve “Process out of Memory Exception” in Node.js ?

Technology CommunityCategory: Node.jsHow to solve “Process out of Memory Exception” in Node.js ?
VietMX Staff asked 3 years ago

To solve the process out of memory exception in Node.js we need to increase the max-old-space-size. By default the max size of max-old-space-size is 512 mb which you can increase by the command:

node --max-old-space-size=1024 file.js