In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-20 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
In this article, the editor introduces in detail "what is the concept of rss in linux", the content is detailed, the steps are clear, and the details are handled properly. I hope this article "what is the concept of rss in linux" can help you solve your doubts.
In linux, the full name of rss is "Resident Set Size", which refers to the resident memory set, which indicates the actual physical memory occupied by the corresponding process in the RAM, but does not include the virtual memory occupied in the SWAP. RSS does not include memory that enters the swap partition, but does include memory occupied by shared libraries (as long as the shared library is in memory).
The operating environment of this tutorial: CentOS 6 system, Dell G3 computer.
There are two nouns RSS and VSZ in Linux memory management, whether it is the top command or the ps command. Example:
[root@localhost ~] # ps aux# View all processes in the system USER PID% CPU% MEM VSZ RSS TTY STAT START TIME COMMANDroot 1 0.0 0.2 2872 1416? Ss Jun04 0:02 / sbin/initroot 2 0.0 0.0 0 0? S Jun04 0:00 [kthreadd] root 3 0.0 0.0 00? S Jun04 0:00 [migration/0] root 4 0.0 0.0 00? S Jun04 0:00 [ksoftirqd/0]... Omit part of the output.
Here's a look at RSS and VSZ.
Linux RSS
RSS is the resident memory set (Resident Set Size), which represents the actual physical memory occupied by the corresponding process in the RAM, but does not include the virtual memory occupied in the SWAP. Even the amount of memory in memory that uses shared libraries is counted, including the full memory in stack and heap.
RSS does not include memory that enters the swap partition.
RSS includes memory occupied by shared libraries (as long as the shared libraries are in memory)
RSS includes all allocated stack memory and heap memory.
Linux VSZ
VSZ (Virtual Memory Size), which indicates the virtual memory size, indicates all the memory that the process can access, including swapped memory and shared library memory.
The VSZ includes all the memory that the process can access, including what goes into the swap partition, and the memory occupied by the shared library.
Example:
If the binary size of process An is 500KB and is linked to the shared library of 2500KB, there is the size of stack/heap of 200KB, where 100KB is in memory and 100KB is in SWAP space, and 1000KB's shared library and 400KB's own binaries are loaded. Then
RSS:
400K + 1000K + 100K = 1500K
VSZ
500K + 2500K + 200K = 3200K
Part of the RSS comes from shared libraries, which may be used by many processes, so if you add up the RSS of all processes, it may be larger than the system memory.
There is a newer parameter, PSS (proportional set size), which calculates shared memory differently from RSS. Referring to the previous example, if two processes use the same shared library, then:
PSS:
400K + (1000K/2) + 100K = 400K + 500K + 100K = 1000K
Threads share the same address space, so all threads within a process have the same RSS, VSZ, and PSS. You can use the ps or top command to observe this information.
After reading this, the article "what is the concept of rss in linux" has been introduced. If you want to master the knowledge of this article, you still need to practice and use it to understand it. If you want to know more about related articles, please follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.