In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces the Linux memory monitoring virtual memory implementation mechanism and capacity setting example analysis, the article is very detailed, has a certain reference value, interested friends must read it!
In the address mapping, physical pages should be found through TLB (translation backup memory); exchange cache should also be used in the exchange mechanism, and the page table should be modified to map the document address after swapping the physical page content into the exchange document.
(1) Linux memory monitoring virtual memory implementation mechanism
The implementation of Linux memory monitoring Linux virtual memory needs the support of six mechanisms: address mapping mechanism, memory allocation recovery mechanism, cache and refresh mechanism, request page mechanism, exchange mechanism, memory sharing mechanism.
First of all, the memory management program maps the logical address of the user program to the physical address through the mapping mechanism, and when the user program is running, if it finds that the virtual address to be used in the program does not have the corresponding physical memory, the request page needs If there is free memory to allocate, request the allocation of memory (hence memory allocation and recycling) and record the physical pages in use in the cache (using the caching mechanism). If there is not enough memory to allocate, the swap mechanism is called to free up some memory. In addition, physical pages should be found through TLB (translation backup memory) in address mapping; exchange cache should also be used in the exchange mechanism, and the page table should be modified to map the document address after swapping the physical page content into the exchange document.
(2) Linux memory monitoring virtual memory capacity setting
Someone may tell you that virtual memory should be allocated twice as much as physical memory, but this is not a fixed rule. If your physical save is relatively small, you can set it this way. If you have 1 gigabyte of physical memory or more, you can shrink the virtual memory. Linux uses a lot of memory for Cache, but it is recycled when resources are tight. As long as you see that the swap is 0 or very small, you can rest assured, because it is a waste of storage that it is not used.
The above is all the contents of the article "example Analysis of Linux memory Monitoring Virtual memory implementation Mechanism and capacity setting". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to 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.