• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.

Question [PPP-56792] Increase NodeJS Memory

raulabad98

New Pleskian
Hello, good morning:

I would like to increase the memory limit for the NodeJS application, however, I don't get the desired result.

The closest result is: 'export NODE_OPTIONS=--max-old-space-size=<size>', however, this is done globally and I would like to keep a separate configuration for each app I have.

What do I need to do? Thanks in advance.
 
hello @raulabad98

you can open nodeJS settings for exact domain and try to use Custom environment variables control
to define max-old-space-size for exact this domain.

1649754587338.png
 
hello:
hello @raulabad98

you can open nodeJS settings for exact domain and try to use Custom environment variables control
to define max-old-space-size for exact this domain.

View attachment 20582
I have dealt with:
  • max-old-space-size
  • --max-old-space-size
  • max_old_space_size
  • --max_old_space_size
  • __max_old_space_size

None of the above works for me, as I apply a test to it and it always fills up the RAM by default, are you sure it's ok what you are telling me?
 
my apologies,
custom variable should be 'NODE_OPTIONS' and the value should be '--max-old-space-size=XX'
 
my apologies,
custom variable should be 'NODE_OPTIONS' and the value should be '--max-old-space-size=XX'
sorry it's me again,

I tried with 'NODE_OPTIONS' and '--max-old-space-size=XX', however, it shows me again that it consumes the default memory, what I realize is that with the global environment variable in linux, when I run the test through PuTTY, it respects the limit of 512, however, if I do it through PLESK, it consumes the default memory, which is 2gb if I'm not mistaken.

I'm seriously thinking of giving up, uninstall PLESK and do it the old-fashioned way, just by command line.
 
@raulabad98 ,
I've passed your feedback to the development team. Too sad that it does not work this way, but we'll investigate this use case and going to improve our product if it is possible.

As a workaround I can suggest you to try Plesk extension called 'Plesk Cgroups Manager'.
It allows to limit CPU and Memory usage for the subscription.

not exactly what you want, but probably it is better than nothing for now.
 
Plesk Cgroups Manager: I have the options set to unlimited.
I will continue to investigate and if not, if I uninstall it, I still appreciate your support.
 
Back
Top