最近刚换了服务器,开始测试的时候未发现什么问题,可是一旦同一时间段操作的人比较多的时候,就会抛出如下错误:

Server Error in '/' Application.

Exception of type 'System.OutOfMemoryException' was thrown.
   Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.

开始的时候,以为是程序错误,后来发现,所有的画面就有这个错误,于是,就估计是服务器的问题,于是就试着将IIS重新启动,果然问题解决了

可是,治标不治本,后来的几天,每天都会不定时的抛出这个错误,终于意识到,这个肯定不是偶然的,于是开始上网搜索对应的解决方法。终于找到了正确的方法

1 查找到服务器对应的路径下的:C:\Windows\Microsoft.NET\Framework\v4.0.30319(注意对应的framework版本)-->Aspnet.config

2 在<runtime> 节点下添加<gcServer enabled="false" />这句话即可

<?xml version="1.0" encoding="UTF-8" ?>
<configuration>
<runtime>
<gcServer enabled="false" />
<legacyUnhandledExceptionPolicy enabled="false" />
<legacyImpersonationPolicy enabled="true"/>
<alwaysFlowImpersonationPolicy enabled="false"/>
<SymbolReadingPolicy enabled="1" />
<shadowCopyVerifyByTimestamp enabled="true"/>
</runtime>
<startup useLegacyV2RuntimeActivationPolicy="true" />
</configuration>

Exception of type 'System.OutOfMemoryException' was thrown的更多相关文章

  1. (C# Debug)A first chance exception of type 'System.ArgumentException' occurred in System.Data.dll

    Debug 模式下运行程序的时候,Output 窗口出来个错误“A first chance exception of type 'System.ArgumentException' occurred ...

  2. java-No exception of type ConfigurationException can be thrown; an exception type must be a subclass of Throwable

    功能:读配置文件 java菜鸟:导入工程在报名处就开始报错,第一次遇到 import org.apache.commons.lang3.StringUtils; import org.apache.c ...

  3. MVC中异常: An exception of type 'System.Data.ProviderIncompatibleException' occurred in EntityFramework.dll的一种解决办法

    今天在调试MVC的例子的时候,总是出错(An exception of type 'System.Data.ProviderIncompatibleException' occurred in Ent ...

  4. An unhandled exception of type 'System.TypeInitializationException' occurred in System.ServiceModel.dll

    异常“ An unhandled exception of type 'System.TypeInitializationException' occurred in System.ServiceMo ...

  5. Form' threw an exception of type 'System.InvalidOperationException'

    环境:VS2017 NetCore 2.2 Razor Layui 在处理异步请求是遇到"((Microsoft.AspNetCore.Http.Internal.DefaultHttpRe ...

  6. "System.OutOfMemoryException" exception when you execute a query in SQL Server Management Studio (转自MSDN)

    Symptoms When you use Microsoft SQL Server Management Studio (SSMS) to run an SQL query that returns ...

  7. 操作XmlDocument时,出现"System.OutOfMemoryException"异常,如何解决加载大数据的情况?

    System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.at System.St ...

  8. .Net 内存溢出(System.OutOfMemoryException)的常见情况和处理方式总结

    .Net 内存溢出(System.OutOfMemoryException)的常见情况和处理方式总结 在什么情况下会出现OutOfMemonryException呢? 在我们试图新建一个对象时,而垃圾 ...

  9. .Net 内存溢出(System.OutOfMemoryException)

    .Net 内存溢出(System.OutOfMemoryException) 在什么情况下会出现OutOfMemonryException呢? 在我们试图新建一个对象时,而垃圾收集器又找不到任何可用内 ...

随机推荐

  1. C++测试题练习题1

    1.which of the following is not automatically generated by the compiler? a. default constructor    b ...

  2. 网上常用免费webservice_查询(网络复制)

    MP3在线搜索服务 地址:http://www.wopos.com/webservice/song.asmx 介绍: 使用: getMusicList()方法搜索MP3/WMA等音乐文件 多功能条形码 ...

  3. maven仓库中有jar包pom还报错

    maven仓库中有jar包pom还报错 就报错,咋啦? 这个包来源不明,自己拷贝进来的吧?你当我mvn是傻子?我要去网上验证一下: 我自己有个_remote.respositories文件,如果自己用 ...

  4. linux中判断符号[]注意事项

    1.中括号[]内的每个组件都需要有空格键来分割: 2.在中括号内的变量,最好都一双引号括号起来: 3.在中括号内的常量,最好都以单引号或双引号括号起来.

  5. java Excel导入、自适应版本、将Excel转成List<map>对象

    转载:http://blog.csdn.net/u012662357/article/details/58593020 最近在web开发中遇到excel批量导入,在网上搜了下很少有将excel直接转成 ...

  6. 出自 HTML4 规范的可用颜色字符串值列表(常用颜色名称及对应的十六进制值)

    据称由于 HTML5 没有修改专属的颜色,HTML4 的颜色都可以在 HTML5 中正确显示. 出自 HTML4 规范的可用颜色字符串值列表如下,此表来源是 http://www.lovean.com ...

  7. spring 官方文档

    英文 http://docs.spring.io/spring/docs/current/spring-framework-reference/htmlsingle/ 翻译(1-6章) http:// ...

  8. hdu4405Aeroplane chess 概率dp水题

    //从0到n有n+1个格子 //对于格子i,掷一次骰子的数为x.那么能够从位置i到位置i+x //格子之间有连线,假设格子a和b有连线,那么从a到b不用掷骰子 //求从0到n的骰子掷的次数的期望 // ...

  9. SAS连接MYSQL的步骤及引用数据表

    1.建立逻辑库 libname  dz  ’物理路径'; 2.逻辑库做为桥梁连接SAS与MYSQL libname dz MYSQL USER=*****  PASSWORD=****  DATABA ...

  10. 1.1 合用weightSum属性和layout_weight属性

    <打造高质量Android应用:Android开发必知的50个诀窍>第1章活用布局,本章将介绍Android布局相关的一些窍门和建议.通过本章,读者不仅可以学习如何从零开始创建特定类型的布 ...