Heap fragmentation can cause a server application that is expected to run continuously for many months to suddenly start malfunctioning thinking that it\'s out of memory.
A good starting point is to enable the low fragmentation heap and check weather it still fragments.
HANDLE heaps[1025];
DWORD nheaps = GetProcessHeaps((sizeof(heaps) / sizeof(HANDLE)) - 1, heaps);
for (DWORD i = 0; i < nheaps; ++i) {
ULONG enableLFH = 2;
HeapSetInformation(heaps[i], HeapCompatibilityInformation, &enableLFH, sizeof(enableLFH));
}
This newly introduced memory manager is switched on by default on Vista/Server 2008 ... So if you determine that world is better on newer Server OS this might be the reason.
The low fragmentation heap was introduced with a service pack of Windows 2000 but it has to be aktively enabled till Windows Vista.
There is a tool vmmap which gives an overview on memory easy and gives a good overview if fragmentation happens.