<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx</link><description>Excessive cached read I/O is a growing problem. For over one year we have been working on this problem with several companies. You can read more about it in the original blog post: http://blogs.msdn.com/ntdebugging/archive/2007/11/27/too-much-cache.aspx</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9468763</link><pubDate>Tue, 10 Mar 2009 10:14:47 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9468763</guid><dc:creator>Barkingdog</dc:creator><description>&lt;P&gt;I downloaded DynCache for x64 systems. The ReadMe file indicates&lt;/P&gt;
&lt;P&gt;"3) Import the DynCache.reg registry file. &amp;nbsp;This registry file contains default settings that you will probably want to modify. &amp;nbsp;"&lt;/P&gt;
&lt;P&gt;Contents of file reproduced below. Can anyone offer clarification of what I can modify? (Server in questionis x64, 16GB RAM. Sql 2005 x64) .&lt;/P&gt;
&lt;P&gt;Thanks, Barkingdog&lt;/P&gt;
&lt;P&gt;Windows Registry Editor Version 5.00&lt;/P&gt;
&lt;P&gt;[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DynCache\Parameters]&lt;/P&gt;
&lt;P&gt;"BackOffMBytesOnLowMemory"=dword:000001f4&lt;/P&gt;
&lt;P&gt;"MaxSystemCacheMBytes"=dword:00000000&lt;/P&gt;
&lt;P&gt;"MinSystemCacheMBytes"=dword:00000064 &amp;nbsp; &amp;nbsp; &amp;nbsp;(MIN &amp;gt; MAX &amp;nbsp;???)&lt;/P&gt;
&lt;P&gt;"SampleIntervalSecs"=dword:0000003c&lt;/P&gt;
&lt;P&gt;"CacheUpdateThresholdMBytes"=dword:00000064&lt;/P&gt;
&lt;P&gt;[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DynCache\Parameters\Notepad]&lt;/P&gt;
&lt;P&gt;"AdditionalBackoffMBytes"=dword:0000000a&lt;/P&gt;
&lt;P&gt;[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DynCache\Parameters\sqlservr]&lt;/P&gt;
&lt;P&gt;"AdditionalBackOffCounter"="\\SQLServer:Memory Manager\\Total Server Memory (KB)"&lt;/P&gt;
&lt;P&gt;[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DynCache\Parameters\System]&lt;/P&gt;
&lt;DIV class=commentowner&gt;[Great question! The “Configuration” section in the readme file explains what each of these registry keys control. The included registry file is just a base template or starting point. In the included example, the minimum System Cache Mbytes is set to 100 Mbytes. The maximum is set to 0, which means limit the system file cache to 90% of physical RAM (default).]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9472773</link><pubDate>Fri, 13 Mar 2009 09:19:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9472773</guid><dc:creator>anonymuos</dc:creator><description>&lt;P&gt;Why are there folders for i386 and IA64 in the released package?&lt;/P&gt;
&lt;DIV class=commentowner&gt;[On Windows Server 2008 x86 (32 bit) the System File Cache doesn’t have the ~1 GB theoretical limit like it did with Windows Server 2003 x86 (32 bit). The System File Cache can grow to consume nearly all of the kernel address space (2GB). The i386 (32 bit) folder is there for managing the size of the System File Cache for 32 bit servers. The IA64 folder is there for servers running on Intel IA-64 processors (not to be confused with AMD’s x64 processor that Intel has licensed).]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9499584</link><pubDate>Sun, 22 Mar 2009 23:34:08 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9499584</guid><dc:creator>ssdguy</dc:creator><description>&lt;P&gt;I'm experiencing system slowness due to slow writes to a SSD. I’m aware of the risks but... ¿is it possible to increase the system write cache and/or reduce the write pace of dirty pages of the cache to the disk? ¿Which is the role of the “Writewatch” on HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management (no info on Technet about it)? &lt;/P&gt;
&lt;P&gt;I have been reading your posts about the memory management but I can’t see a way to preserve part of the cache for writes (I can set the maximum amount of memory for cache with your excellent Microsoft Windows Dynamic Cache Service and the amount of dirty pages with SystemCacheDirtyPageThreshold)&lt;/P&gt;
&lt;P&gt;I’m using the LargeSystemCache configuration and the disk CacheIsPowerProtected and UserWriteCacheSetting options are set. All I want is to cache more writes into memory. It will be fantastic to be able to cache “write through” requests also (more risks but I can handle them)&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;
&lt;DIV class=commentowner&gt;[Sounds like you need Windows 7. Windows (before Windows 7) was designed to support conventional hard drives. While SSDs present themselves as conventional hard drives, there are some caveats as you are well aware of. With Windows 7 we added enhancements to improve the usage of SSDs. We will disable defrag, make larger write clusters, reduce read/write cycles, etc. These enhancements should extend SSD lifespan and improve SSD I/O performance over previous versions of Windows. The 'WriteWatch' registry key was used to watch modification of pages in physical memory. After Windows 2000, this registry key is no longer used. For current versions of Windows you should always disable disk defragmenters on SSD drives. If you have enough physical memory, you could disable paging of the Executive with the 'DisablePagingExecutive' registry key. You could even turn off the paging file to reduce write and read I/O to your drive. Please be aware, that if you turn off the paging file, you will not only be unable to collect a memory dump file, but the system could run out of available memory. I can't recommend anything that would prevent "write through" writes. If the system ever hangs, crashes or powers off unexpectedly, then you could lose critical writes (like to the registry). The system may end up being unbootable.]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9527584</link><pubDate>Wed, 01 Apr 2009 21:59:35 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9527584</guid><dc:creator>ssdguy</dc:creator><description>&lt;p&gt;Thanks for your answer!&lt;/p&gt;
&lt;p&gt;Most of your recommendations are generic for most “old SSD” that have too much problems shuttering due to writes. I have not enough memory to disable the page file (only 4 GB) but I have configured the page file on another mechanical disk and I have disabled defrag and paging executive.&lt;/p&gt;
&lt;p&gt;I know that preventing &amp;quot;write through&amp;quot; writes can be a bad idea in general and the system may end unbootable but it is like having your SO on a RAID 0. Enabling &amp;quot;write caching&amp;quot; and &amp;quot;advanced performance&amp;quot; check on disks without having a real backup power supply is also &amp;quot;risky&amp;quot; but it is not so bad if you know what you are doing.&lt;/p&gt;
&lt;p&gt;In the end you risk the integrity of the system to gain performance... Like all of life, is about tradeoffs. I don't want you recommend that as a &amp;quot;best practice&amp;quot; but it is interesting to know how it is possible to achieve this behavior or if it is impossible on Windows.&lt;/p&gt;
&lt;p&gt;For example it can be very useful for demo virtual machines that need to run as fast as possible and you will disregard the changes after the demo anyway.&lt;/p&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9538808</link><pubDate>Wed, 08 Apr 2009 22:36:48 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9538808</guid><dc:creator>john</dc:creator><description>&lt;P&gt;The folder has &amp;nbsp;amd64, i386, and ia64.&lt;/P&gt;
&lt;P&gt;Where is the folder just for 64-bit, NOT ia64 and amd64?&lt;/P&gt;
&lt;P&gt;Where is the Windows Dynamic Cache service for 64-bit server &lt;/P&gt;
&lt;P&gt;that is NOT IA or AMD?&lt;/P&gt;
&lt;P&gt;thanks&lt;/P&gt;
&lt;DIV class=commentowner&gt;[All 64 bit installs should use the amd64 bit folder. Unless you’re running an Itanium machine which uses the ia64 folder, you should use the amd64 folder.]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9557185</link><pubDate>Mon, 20 Apr 2009 22:46:29 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9557185</guid><dc:creator>LC</dc:creator><description>&lt;P&gt;You mentioned above: &amp;nbsp;"So that brings us back to the only provided solution - use the provided APIs."&lt;/P&gt;
&lt;P&gt;This solution is only for 64-bit machines right? &amp;nbsp;Based on your explanations above, it sounds like a 32-bit OS wouldn't suffer from this memory issue. &amp;nbsp;Meaning someone could 'downgrade' their OS to 32-bit and basically escape this issue altogether right? &amp;nbsp;&lt;/P&gt;
&lt;P&gt;LC&lt;/P&gt;
&lt;DIV class=commentowner&gt;[Hello LC. Unfortunately 32 bit Vista/Server08 systems could experience worse problems.&amp;nbsp; Prior to Vista, on 32 bit system, kernel resources were limited to certain virtual address ranges.&amp;nbsp; This ended up restricting the system file cache’s working set size to a theoretical limit of about 1 GB. &amp;nbsp;Since most systems have more than 1 GB of physical RAM you were generally not affected by this problem Starting with Vista, the Memory Manager can allocate kernel resources anywhere in the kernel virtual address space. This allows critical resources like paged and non-paged pool to grow larger than they previously could.&amp;nbsp; Unfortunately, this change also allows the system file cache’s working set to grow and consume all of kernel virtual memory.&amp;nbsp; Since the kernel virtual address space is limited to 2GB of virtual memory, the system file cache doesn’t have to consume all of physical RAM.&amp;nbsp; Once it consumes all of the kernel virtual address space, allocations in critical resources like paged and non-paged pool may start failing.&amp;nbsp; If these critical allocations start failing, you’ll get all kinds of generic errors from not enough system resources to access denied to application and system crashes.&amp;nbsp; So for 32 bit Vista/Server 08 systems you have less virtual address range to play in.&amp;nbsp; You can consume it quicker and if you do, you may end up with worse problems than a slow computer.]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9805976</link><pubDate>Sat, 27 Jun 2009 00:09:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9805976</guid><dc:creator>Dan</dc:creator><description>&lt;P&gt;I have a SQL Server 2005 install that has 15 active instances, none of them the default one. &amp;nbsp;I think this may help my issue with "There is insufficient system memory to run this query", but I would need to add the different counters for the different instances (each instance has it's own counter in the form of MSSQL$INSTANCENAME). &amp;nbsp;Any recommendations on how to tackle this?&lt;/P&gt;
&lt;P&gt;See &lt;A href="http://social.msdn.microsoft.com/Forums/en-US/sqldatabaseengine/thread/d9590d4b-6daa-4bf4-8384-06a644f3983e" rel=nofollow target=_new&gt;http://social.msdn.microsoft.com/Forums/en-US/sqldatabaseengine/thread/d9590d4b-6daa-4bf4-8384-06a644f3983e&lt;/A&gt;&lt;/P&gt;
&lt;DIV class=commentowner&gt;[You should first verify that you are running low on physical memory when you get these errors. An error like this can be caused by numerous problems, some not even related to memory depletion. You should collect performance monitor logs and analyze the specific times of the failures. If you are running low on physical memory and most of the physical RAM is used by the cache, then this service could help you. Out of the box, you can monitor only 1 additional counter per process. If you need to monitor multiple counters, you’ll need to add additional code to the project and recompile the service.]&lt;/DIV&gt;</description></item><item><title>re: Microsoft Windows Dynamic Cache Service</title><link>http://blogs.msdn.com/ntdebugging/archive/2009/02/06/microsoft-windows-dynamic-cache-service.aspx#9900980</link><pubDate>Tue, 29 Sep 2009 23:34:37 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9900980</guid><dc:creator>Jay</dc:creator><description>&lt;P&gt;I'm trying to mimic the setcache.exe behavior. If I set MaxSystemCacheMBytes to &amp;nbsp;4096 and MinSystemCacheMBytes would be 0 (the default which is 100MB), start the dynamic cache service and then run setcache.exe it appears that the settings have not been activated. Is this expected behavior or am I missing something? 
&lt;DIV class=commentowner&gt;[What operating system and processor architecture (x86 or x64) are you using? If you are on x64, make sure that you are using the 64 bit version of DynCache.exe. The minimum cache size is 100 Mbytes (unless you change the code and recompile). This is just a safety guard and I highly recommend that you do not set the minimum to below 100 Mbytes. If you are on x86, then use a number less than 4096 as the 32 bit API has this as an upper limit. Also make sure you have over 4096 Mbytes available for the cache to potentially grow into. You can use the debug build of DynCache.exe along with Debug View to collect a log of what the service doing on start up.]&lt;/DIV&gt;</description></item></channel></rss>