Database Reference
In-Depth Information
Figure 7.9 Enabling large pages.
What Is a Large Page?
All operating systems have a page size with which they work in memory. With
Windows, the normal page size for a X64 system is 4KB. That means all work within
memory happens in 4KB increments. This means all access to the buffer pool happens in
4KB chunks. When you enable large pages, the size is moved up to 2MB. A large page
is many orders of magnitude larger than the default page size. The difference in page
sizes is like the difference between moving your data with a pickup truck versus a very
long cargo train. The immediate gain is that address translations happen much faster.
This is because there are many fewer memory pages to manage. In other words, memory
can be allocated quicker to the virtual machine, which translates into faster performance
for your database.
Upon database startup when large pages are enabled, the database will immediately
allocate all memory for the buffer pool rather than grow it dynamically. By having all
pages allocated up front, SQL Server avoids the risk of memory fragmentation or out-of-
memory conditions later. Another added benefit: Because the allocation of large pages
can take some time if it happens dynamically, you now avoid a performance hit that
would happen later when your database queries are first initiated.
Large pages must be in contiguous space within memory, which is why it's important
that they be implemented with many of the other suggestions we made earlier in this
chapter. For example, memory reservations will help ensure you have a large chunk of
contiguous space.
 
 
 
Search WWH ::




Custom Search