Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support process share memory metrics. #321

Open
magiceses opened this issue Oct 28, 2024 · 3 comments
Open

Support process share memory metrics. #321

magiceses opened this issue Oct 28, 2024 · 3 comments

Comments

@magiceses
Copy link

I see that the memory now supports three values, can you support the indicator output of shared memory?

@SilenceAdele
Copy link

I also need to get the shared memory of the process, but I found that the latest version v0.8.4 does not implement it. I want to know why it is not implemented? @rfratto @ncabatoff

@SilenceAdele
Copy link

SilenceAdele commented Dec 5, 2024

  • In the top command, the size of the process's shared memory can be obtained through SHR.
PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND
58984 diag      20   0 2119424 185436  35180 S   1.0   0.1 234:02.02 qemu-kvm
  • However, the namedprocess_namegroup_memory_bytes indicator in process-exporter does not monitor the process's shared memory.
namedprocess_namegroup_memory_bytes{groupname="qemu-kvm",memtype="proportionalResident"} 6.485661696e+09
namedprocess_namegroup_memory_bytes{groupname="qemu-kvm",memtype="proportionalSwapped"} 0
namedprocess_namegroup_memory_bytes{groupname="qemu-kvm",memtype="resident"} 6.593572864e+09
namedprocess_namegroup_memory_bytes{groupname="qemu-kvm",memtype="swapped"} 0
namedprocess_namegroup_memory_bytes{groupname="qemu-kvm",memtype="virtual"} 2.7006369792e+10
  • The role of shared memory monitoring of processes in actual production
  1. In a virtualized or containerized environment, multiple virtual machines or containers may share the host machine's memory. If a virtual machine or container occupies too much shared memory, it may affect the memory resources of other virtual machines or containers, resulting in limited memory access, delays or crashes.
  2. If a long-running virtual machine or container does not release shared memory correctly, it may cause the shared memory to continue to grow, eventually affecting the stability of the entire system.

@rfratto @ncabatoff

@SilenceAdele
Copy link

ping...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants