#support

Monitoring Memory Consumption in NodeJS App

TLDR abhinav wants to monitor memory consumption in their NodeJS app using host metrics. Srikanth advises that they can track it using the process_memory_usage metric.

Powered by Struct AI
8
5mo
Solved
Join the chat
Apr 14, 2023 (5 months ago)
abhinav
Photo of md5-e02e105da483c3727bd042f935991ec6
abhinav
07:22 AM
I wanna know if my nodeJs app is consuming the memory
Srikanth
Photo of md5-ce04a9988e2fd758a659dc55be6f2543
Srikanth
07:39 AM
https://slack.com/intl/en-in/help/articles/115000769927-Use-threads-to-organise-discussions-

No, you don’t need to install the infra agent if you are already using the host metrics. If you want to see process_memory_usage which will contain the command used to start the process and search for the appropriate node process.
abhinav
Photo of md5-e02e105da483c3727bd042f935991ec6
abhinav
10:15 AM
I am using host metrics and puttig it on grafana
Srikanth
Photo of md5-ce04a9988e2fd758a659dc55be6f2543
Srikanth
10:23 AM
I didn’t understand. What are you trying to convey?
abhinav
Photo of md5-e02e105da483c3727bd042f935991ec6
abhinav
10:43 AM
I have only installed APM for my nodeJS app and not the infra agent of signoz
10:43
abhinav
10:43 AM
yet i want to know the reason of memory leak
10:43
abhinav
10:43 AM
how can i create such a dashboard for the same?
Srikanth
Photo of md5-ce04a9988e2fd758a659dc55be6f2543
Srikanth
11:03 AM
> yet i want to know the reason of memory leak
The dashboard can only help you know the current memory usage. They will not tell you the reason for the memory leak. As I mentioned earlier, if you are already using the host-metrics package, you do not need to run the “infra agent” to collect system or process memory usage. There will be a metric named process_memory_usage which can be used to track the memory consumption of a particular kind of process.