hugepages優化記憶體原理與優點
hugepages優化記憶體原理與優點
hugepages 優化=>SGA ,PGA不優化
一、hugepages優化原理:
1.1 減少了PTE的使用,進而增加了LTB的命中率
PTE=>page the entry
LTB=>Translation Lookaside Buffer
1.2 大頁與普通的區別
hugepage size from 2m to 256m
normal size 4k
1.3 官方介紹:hugepages
http://docs.oracle.com/cd/E11882_01/install.112/e41961/memry.htm#CWLIN383
What HugePages Provides
HugePages is a feature integrated into the Linux kernel with release 2.6. It is a method to have larger pages where it is useful for working with very large memory. It can be useful for both 32-bit and 64-bit configurations. HugePage sizes vary from 2MB to 256MB, depending on the kernel version and the hardware architecture. For Oracle Databases, using HugePages reduces the operating system maintenance of page states, and increases TLB (Translation Lookaside Buffer) hit ratio.
Without HugePages, the operating system keeps each 4 KB of memory as a page, and when it is allocated to the SGA, then the lifecycle of that page (dirty, free, mapped to a process, and so on) must be kept up to date by the operating system kernel.
With HugePages, the operating system page table (virtual memory to physical memory mapping) is smaller, since each page table entry is pointing to pages from 2 MB to 256 MB. Also, the kernel has fewer pages whose lifecyle must be monitored.
For example, if you use HugePages with 64-bit hardware, and you want to map 256 MB of memory, you may need one page table entry (PTE). If you do not use HugePages, and you want to map 256 MB of memory, then you must have 256 MB * 1024 KB/4 KB = 65536 PTEs.
二、hugepages使用的優點
http://docs.oracle.com/cd/E11882_01/server.112/e10839/appi_vlm.htm#UNXAR395
The following are the advantages of using HugePages:
Increased performance through increased TLB hits.
Pages are locked in memory and are never swapped out which guarantees that shared memory like SGA remains in RAM.
Contiguous pages are preallocated and cannot be used for anything else but for System V shared memory (for example, SGA)
Less bookkeeping work for the kernel for that part of virtual memory due to larger page sizes
hugepages 優化=>SGA ,PGA不優化
一、hugepages優化原理:
1.1 減少了PTE的使用,進而增加了LTB的命中率
PTE=>page the entry
LTB=>Translation Lookaside Buffer
1.2 大頁與普通的區別
hugepage size from 2m to 256m
normal size 4k
1.3 官方介紹:hugepages
http://docs.oracle.com/cd/E11882_01/install.112/e41961/memry.htm#CWLIN383
What HugePages Provides
HugePages is a feature integrated into the Linux kernel with release 2.6. It is a method to have larger pages where it is useful for working with very large memory. It can be useful for both 32-bit and 64-bit configurations. HugePage sizes vary from 2MB to 256MB, depending on the kernel version and the hardware architecture. For Oracle Databases, using HugePages reduces the operating system maintenance of page states, and increases TLB (Translation Lookaside Buffer) hit ratio.
Without HugePages, the operating system keeps each 4 KB of memory as a page, and when it is allocated to the SGA, then the lifecycle of that page (dirty, free, mapped to a process, and so on) must be kept up to date by the operating system kernel.
With HugePages, the operating system page table (virtual memory to physical memory mapping) is smaller, since each page table entry is pointing to pages from 2 MB to 256 MB. Also, the kernel has fewer pages whose lifecyle must be monitored.
For example, if you use HugePages with 64-bit hardware, and you want to map 256 MB of memory, you may need one page table entry (PTE). If you do not use HugePages, and you want to map 256 MB of memory, then you must have 256 MB * 1024 KB/4 KB = 65536 PTEs.
二、hugepages使用的優點
http://docs.oracle.com/cd/E11882_01/server.112/e10839/appi_vlm.htm#UNXAR395
The following are the advantages of using HugePages:
Increased performance through increased TLB hits.
Pages are locked in memory and are never swapped out which guarantees that shared memory like SGA remains in RAM.
Contiguous pages are preallocated and cannot be used for anything else but for System V shared memory (for example, SGA)
Less bookkeeping work for the kernel for that part of virtual memory due to larger page sizes
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26442936/viewspace-1372443/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Android系統Bitmap記憶體分配原理與優化Android記憶體優化
- 實踐App記憶體優化:如何有序地做記憶體分析與優化APP記憶體優化
- Android效能優化篇之記憶體優化--記憶體洩漏Android優化記憶體
- Android 效能優化之記憶體優化Android優化記憶體
- Android記憶體優化Android記憶體優化
- android效能評測與優化-記憶體Android優化記憶體
- android記憶體管理機制與優化Android記憶體優化
- Android記憶體優化之圖片優化Android記憶體優化
- 反射記憶體卡的優勢與特點反射記憶體
- 記憶體優化相關記憶體優化
- Android Note - 記憶體優化Android記憶體優化
- 關於redis記憶體分析,記憶體優化Redis記憶體優化
- 2.記憶體優化(二)優化分析記憶體優化
- 高德地圖駕車導航記憶體優化原理與實戰地圖記憶體優化
- 1.記憶體優化(一)記憶體洩漏記憶體優化
- JNI記憶體管理及優化記憶體優化
- mariadb 記憶體佔用優化記憶體優化
- iOS圖片記憶體優化iOS記憶體優化
- App記憶體優化-實踐APP記憶體優化
- 淺談Android記憶體優化Android記憶體優化
- Android記憶體優化全解析Android記憶體優化
- Redis-記憶體優化(一)Redis記憶體優化
- win10怎麼優化記憶體 win10系統記憶體優化的方法Win10優化記憶體
- iOS 使用Instruments優化記憶體效能iOS優化記憶體
- Linux 效能優化之 記憶體 篇Linux優化記憶體
- MongoDB記憶體使用分析和優化MongoDB記憶體優化
- HBase記憶體配置及JVM優化記憶體JVM優化
- 記憶體洩漏與排查流程——安卓效能優化記憶體安卓優化
- Redis 記憶體優化在 vivo 的探索與實踐Redis記憶體優化
- win10虛擬記憶體如何優化_win10怎麼優化虛擬記憶體Win10記憶體優化
- Presto記憶體調優及原理(基礎篇)REST記憶體
- Android深度效能優化--記憶體優化(一篇就夠)Android優化記憶體
- win10系統如何優化記憶體_win10優化記憶體佔用率怎麼操作Win10優化記憶體
- Android效能優化,Startalk會話頁GIF記憶體優化實踐Android優化會話記憶體
- Redis 記憶體優化神技,小記憶體儲存大資料Redis記憶體優化大資料
- [BASIS]SAP記憶體優化配置學習記憶體優化
- cocos2d-x 優化(紋理渲染優化、資源快取、記憶體優化)優化快取記憶體
- 讀書筆記2-記憶體優化篇筆記記憶體優化
- Android效能優化:手把手帶你全面實現記憶體優化Android優化記憶體