Posted on 2010/07/22 14:12
Filed Under 분류없음

Site Link :https://access.redhat.com/kb/docs/DOC-15252

Issue

If add several hundred GB of RAM to a system, do really need several hundred GB of swap space ?


Environment

Red Hat Enterprise Linux 5


Resolution

Currently Red Hat recommends a linear increase to the amount of swap space on a system as the amount of RAM increases.  Specifically that swap space on a system be twice the amount of RAM when the system has up to 2GB and the amount of RAM plus 2GB when the system has more than 2GB of RAM. This is pretty much the same recommendation as upstream so the reasoning behind it is, the larger the system, the larger memory workload that system will likely encounter.


This no longer makes sense as memory sizes have increased up into the hundreds of GBs range.


The reality is the amount of swap space a system needs is not really a function of the amount of RAM it has but rather the memory workload that is running on that system.  A Red Hat Enterprise Linux 5 system will run just fine with no swap space at all as long as the sum of anonymous memory and system V shared memory is less than about 3/4 the amount of RAM. In this case the system will simply lock the anonymous and system V shared memory into RAM and use the remaining RAM for caching file system data so when memory is exhausted the kernel only reclaims pagecache memory.


Considering that

1) At installation time when configuring the swap space there is no easy way to predetermine the memory a workload will require, and

2) The more RAM a system has the less swap space it typically needs, a better swap space requirements rule for Red Hat Enterprise Linux 5 is:


  • Systems with 4GB of ram or less require a minimum of 2GB of swap space

  • Systems with 4GB to 16GB of ram require a minimum of 4GB of swap space

  • Systems with 16GB to 64GB of ram require a minimum of 8GB of swap space

  • Systems with 64GB to 256GB of ram require a minimum of 16GB of swap space


크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기(0) 이올린에 추천하기(0)
2010/07/22 14:12 2010/07/22 14:12

트랙백 주소 : http://blog.seabow.pe.kr/trackback/733



About

by 삐꾸강아쥐

Counter

· Total
: 137370
· Today
: 71
· Yesterday
: 0
블로그코리아에 블UP하기