Keep getting message: Failed allocate pages: FAIL_PAGE_ALLOCATION 540
Because there are only 8208 pages allocated to MEMORYCLERK_SQLLOGPOOL in the excerpt not sure kb2769594 is the culprit/fix. Also no reference to internal pool or HADR as in the kb2769594 example. https://support.microsoft.com/kb/2769594
So I think culprit/fix may be something else.
Surprising that no large pages allocated at all - I'd expect some for non-bpool with 8 gb of RAM on the server. SQL Server Enterprise edition? Low system memory is somewhat suprising - is there another large memory consumer beside SQL Server? Which OS version? Is the NTFS file cache well under control?
edit Via twitter also asked if 'lock pages in memory' LPIM is expected - no locked pages indicated above.
Just to provide another answer. I just ran into the same error messages and this issue seems to be related yet not the same issue fixed in the KB linked in the other 2 answers.
The error messages you get seem to indicate the same, but in your case (and mine) it's not MEMORYCLERK_SQLLOGPOOL
that's taking a lot of memory but MEMORYCLERK_XE
that's taking up more memory than you would expect.
After investigation which XE sessions where running it came up with the system_health and 2 Sharepoint sessions (and you seem to be hosting sharepoint too). Those 2 sessions log to the ring buffer target (and log quite a lot of events).
The good news is that according to some blog posts it's still fixed in SP2 for SQL Server 2012 and after a week on SP3 the XE memory clerk seems to be under control.
Related reading:
- https://social.msdn.microsoft.com/forums/sqlserver/en-US/ea3b1e29-d288-4f41-a3f8-3fa1b71e3e82/memoryclerkxe-consuming-30-gb-memory-of-100-gb
- https://geertvanhove.wordpress.com/2015/07/02/memoryclerk_xe-and-sharepoint/
From Geert:
This behaviour is generated by extended events most likely created by Sharepoint monitoring and logging information into memory ring buffers. Disabling ring buffers or a correct configuration of ring buffers should solve this issue.
Wrong, this is a known issue with Sharepoint on SQL Server 2012 SP1. After installing SP2 en restarting the instance, the problem was solved. However, I suggested to keep on monitoring memory clerks for another few weeks.
PS: these errors where also observed in my environment: Using ‘dbghelp.dll’ version ‘4.0.5’
Edit: I can confirm I haven't seen any issues with this server for months so it looks as if the update addressed my issue.
SQL Server in your case is patched to SP1
. Microsoft has released SQL Server 2012 SP2 and there was fix for such type of errors.
As per Microsoft Article reason is
Microsoft SQL Server 2012 may experience some out-of-memory errors because of an internal memory leak. In this situation, the leaked memory is consumed by the MEMORYCLERK_SQLLOGPOOL memory clerk that is used internally for transaction log activities. For example, the MEMORYCLERK_SQLLOGPOOL memory clerk is used internally for the following transaction log activities:
AlwaysOn change-capturing activities on the primary replicas
AlwaysOn redo manager activities on the secondary availability replicas
The article says that issue was fixed in CU2/CU5 for SQL Server 2012 SP1
. But since Microsoft released SQL Server 2012 SP2 this would contain all such fixes and I highly urge you to apply SP2 ASAP
.