Large Pages说明
sun文档:
http://www.oracle.com/technetwork/java/javase/tech/largememory-jsp-137182.html
说白了,就是在操作系统级别上,针对进程的虚拟内存空间,使用大内存页,避免频繁的进行页换入换出,出现系统抖动。同样使用大内存分页,也会有一些负面影响,两快大内存分页之间会出现一些内存碎片,从而影响整体系统的性能,当一旦没有足够的大内存块时,整个OS下系统进程又会将原先的大内存打散恢复默认的内存分页。
摘自sun文档的原话 写道
A Translation-Lookaside Buffer (TLB) is a page translation cache that holds the most-recently used virtual-to-physical address translations. TLB is a scarce system resource. A TLB miss can be costly as the processor must then read from the hierarchical page table, which may require multiple memory accesses. By using bigger page size, a single TLB entry can represent larger memory range. There will be less pressure on TLB and memory-intensive applications may have better performance.
However please note sometimes using large page memory can negatively affect system performance. For example, when a large mount of memory is pinned by an application, it may create a shortage of regular memory and cause excessive paging in other applications and slow down the entire system. Also please note for a system that has been up for a long time, excessive fragmentation can make it impossible to reserve enough large page memory. When it happens, either the OS or JVM will revert to using regular pages.
Linux下如何配置large Page
Large page support is included in 2.6 kernel. Some vendors have backported the code to their 2.4 based releases. To check if your system can support large page memory, try the following:
cat /proc/meminfo | grep Huge
HugePages_Total: 0
HugePages_Free: 0
Hugepagesize: 2048 kB
If the output shows the three "Huge" variables then your system can support large page memory, but it needs to be configured. If the command doesn't print out anything, then large page support is not available. To configure the system to use large page memory, one must log in as root, then:
Increase SHMMAX value. It must be larger than the Java heap size. On a system with 4 GB of physical RAM (or less) the following will make all the memory sharable:
echo 4294967295 > /proc/sys/kernel/shmmax
Specify the number of large pages. In the following example 3 GB of a 4 GB system are reserved for large pages (assuming a large page size of 2048k, then 3g = 3 x 1024m = 3072m = 3072 * 1024k = 3145728k, and 3145728k / 2048k = 1536):
echo 1536 > /proc/sys/vm/nr_hugepages
Note the /proc values will reset after reboot so you may want to set them in an init script (e.g. rc.local or sysctl.conf).
参数配置
sun jdk :
jrockit jdk :
效果
摘录校长的测试结果: 写道
这个设置, 目前观察下来的结果是EDEN区域收集明显速度比较快, 最多几个ms, 但是,对于FGC, 大约需要0。9, 但是发生时间非常的长, 应该是影响不大。 但是对于非web应用的中间件服务, 这个设置很要不得, 可能导致很严重延迟效果.这时需要搭配cms,加速old区的并发收集
分享到:
相关推荐
The man pages are helpful but they are very lengthy and it does not give any clues on key areas where commands can be used. Proper usage of shell commands can easily solve many complex tasks with a ...
The man pages are helpful but they are very lengthy and it does not give any clues on key areas where commands can be used. Proper usage of shell commands can easily solve many complex tasks with a ...
The man pages are helpful but they are very lengthy and it does not give any clues on key areas where commands can be used. Proper usage of shell commands can easily solve many complex tasks with a ...
370 pages in large, easy-to-read 8.5 x 11 inch format Over 9000 lines of Python scripts with explanations Over 800 lines of shell scripts with explanations A 102 page chapter containing up-to-date ...
Then, if you choose, you can transition your skills to manage anything from a small office to a large, corporate Red Hat Enterprise Linux computer installation. This book tells you how and gives you ...
With the Fedora Linux operating system and ...small office to a large, corporate Red Hat Enterprise Linux computer installation. This book tells you how and gives you all the software you need to do it.
Paperback: 282 pages Publisher: Packt Publishing - ebooks Account (November 23, 2015) Language: English ISBN-10: 1785284444 ISBN-13: 978-1785284441 Learn shell scripting to solve complex shell-...
用JSP开发的Web应用是跨平台的,即能在Linux下运行,也能在其他操作系统上运行。 JSP技术使用Java编程语言编写类XML的tags和scriptlets,来封装产生动态网页的处理逻辑。网页还能通过tags和scriptlets访问存在于...
5.6 Case Study: Large Inbound I/O .............................................................................. 18 5.7 Conclusion ........................................................................
JavaServer Pages (JSP) provide a robust solution to developing large, complex Web applications, including multiserver projects. In addition to built-in security, portability, and a Web server, they ...
Before moving to the front end, he worked on several large-scale cloud computing products, using Python and Linux. No stranger to complexity, Adam has practical experience with real-world software ...
2017 | ASIN: B01N5HQ2AE | 310 Pages | AZW3 | 11.56 MB Key Features Learn how to extend Ansible with custom modules, plugins, and inventory sources Utilize advanced Ansible features to orchestrate ...
Masoud's main area of research and interest includes service-oriented architecture and large scale systems' development and deployment and in his leisure time he enjoys photography, mountaineering and...
English | 16 May 2017 | ASIN: B0716YXM1N | 726 Pages | AZW3 | 5.09 MB Learn Chef Provisioning like a boss and discover how to deploy software and manage hosts, along with engaging recipes to automate...
Shows you how to build Accumulo, Hadoop, and ZooKeeper clusters from scratch on both Windows and Linux Allows you to get hands-on knowledge about how to run Accumulo on Amazon EC2, Google Cloud ...
English | 26 July 2017 | ISBN: 1786462745 | ASIN: B01MR4YF5G | 354 Pages | AZW3 | 13.74 MB Advanced analytics on your Big Data with latest Apache Spark 2.x About This Book An advanced guide with a ...
SQUASHFS 2.2 - A squashed read-only filesystem for Linux Copyright 2005 Phillip Lougher (phillip@lougher.demon.co.uk) Released under the GPL licence (version 2 or later). Welcome to Squashfs ...
- Fix MTRR configuration (prevented boot of modern Linux kernels) - Fix interrupt vectors for INT 60h-66h (reserved for user interrupt) by setting them to zero - Fix BIOS INT13 function 08 when ...
On a Linux machine, one must simply invoke the script in a terminal, stating a site to test: motoma@rocksalt:/home/motoma$ python pyloris-3.0.py motomastyle.com On Mac OS X, one invokes PyLoris the ...
compiling JSP pages. This means you no longer need to have the complete Java Development Kit (JDK) to run Tomcat, but a Java Runtime Environment (JRE) is sufficient. The Eclipse JDT Java compiler is ...