Original article reproduced please specify the source: @ http://zeeman.cnblogs.com,
The newly deployed service on the production line, which occurs several times with no reason to stop, is seen through system events:
This service caches a large amount of data, memory consumption is relatively large, but not OutOfMemory (server memory is large), suspected compile-time problems, see the project properties found this Perfer 32-bit is a serious suspicion. Remove this option to recompile the deployment, run all night, no more problems, problem solved. The reason is simple: the 32-bit operating system's addressing space is 4G, of which 2G is occupied by the operating system, that is left to the user process memory only 2G (which also to deduct the program load when the image occupies a portion of space, generally only about 1.6g~1.8g can be used). If the process is running in which memory needs to be requested, and the operating system cannot allocate memory space for it, an out-of-memory exception is generated, in. NET System.OutOfMemoryException (the exception is thrown when there Is isn't enough memory tocontinue the execution of a program.).
. Net 4.5 Executable OutOfMemory