MemToLeave Values

  • As a followup to me earlier thread "Corrupt Backup File", I found the following script here to get some memory information

    http://www.johnsansom.com/sql-server-memory-configuration-determining-memtoleave-settings/

    WITH VAS_Summary AS

    ( SELECT Size = VAS_Dump.Size, Reserved = SUM(CASE(CONVERT(INT, VAS_Dump.Base) ^ 0) WHEN 0 THEN 0 ELSE 1 END),

    Free = SUM(CASE(CONVERT(INT, VAS_Dump.Base) ^ 0) WHEN 0 THEN 1 ELSE 0 END)

    FROM ( SELECT CONVERT(VARBINARY, SUM(region_size_in_bytes)) [Size], region_allocation_base_address [Base]

    FROM sys.dm_os_virtual_address_dump

    WHERE region_allocation_base_address <> 0

    GROUP BY region_allocation_base_address

    UNION

    SELECT CONVERT(VARBINARY, region_size_in_bytes) [Size], region_allocation_base_address [Base]

    FROM sys.dm_os_virtual_address_dump

    WHERE region_allocation_base_address = 0x0 ) AS VAS_Dump

    GROUP BY Size )SELECT SUM(CONVERT(BIGINT, Size) * Free) / 1024 AS [Total avail mem, KB], CAST(MAX(Size) AS BIGINT) / 1024 AS [Max free size, KB]

    FROM VAS_Summary WHERE FREE <> 0

    My results, on a 4 G RAM SQL 2005 box are:

    [font="Courier New"]Total avail mem, KB ..... 10692

    Max free size, KB ....... 668[/font]

    Which seems pretty low

    EDIT: I am seeing this message in the Server Event Log: "AppDomain 9 (data_monitor.dbo[runtime].8) is marked for unload due to memory pressure."

    Any comments or advice while I continue reading ?

Viewing 0 posts

You must be logged in to reply to this topic. Login to reply