System.Data.Entity.Infrastructure.CommitFailedException: An error was reported while committing a database transaction but it could not be determined whether the transaction succeeded or failed on the database server. See the inner exception and http://go.microsoft.com/fwlink/?LinkId=313468 for more information. ---> System.Data.SqlClient.SqlException: Execution Timeout Expired.  The timeout period elapsed prior to completion of the operation or the server is not responding. ---> System.ComponentModel.Win32Exception: 等待的操作过时。

1、日志库初始化空间设置过大,自增长设置为10%,当超过初始值后每次分配的空间过大操作时备份操作日志比较慢超时导致的!https://q.cnblogs.com/q/88805/
2、在数据库执行一下命令就好了:exec sp_updatestats; https://www.cnblogs.com/xujie520/p/10748435.html

3、检查数据库日志文件,发现日志文件大小四十多G,数据日志文件自动增长模式为10%来增长  相当于一次性增长4个多G

sqlserver数据库日志文件自动扩容时需要做很多的事情,非常消耗性能,因此再扩容期间;对于数据库的操作就都会被延迟等等;等到文件扩容结束才能恢复正常

https://blog.csdn.net/liuci820/article/details/79927734     解决方案:

1.先对现有数据库日志文件进行清理;采用压缩方式将日志数据清理掉

2.修改日志文件自动增长方式;不要按照百分比进行增长,根据自己数据库文件大小增长情况合理设置 ;一般设置一次增长再100—200M;

4、https://www.cnblogs.com/Jesse-Li/p/7473178.html

5、设置sqlserver内存占用只使用60%,保证内存充足

6、数据库连接字符串添加;MultipleActiveResultSets=True;

code first System.Data.Entity.Infrastructure.CommitFailedException: An error was reported while committing a database transaction but it could not be determined whether the transaction succeeded的更多相关文章

  1. EF 更新数据出现 System.Data.Entity.Infrastructure.DbUpdateConcurrencyException: 异常

    EF6更新 数据出现 System.Data.Entity.Infrastructure.DbUpdateConcurrencyException: Store update, insert, or  ...

  2. System.Data.Entity.Infrastructure.DbUpdateException

    异常描述:   捕捉到 System.Data.Entity.Infrastructure.DbUpdateException  HResult=-2146233087  Message=无法更新 E ...

  3. system.Data.Entity.Infrastructure.DbUpdateConcurrencyException: Store update, insert, or delete statement affected an unexpected number of rows (0) 问题

    页面控件没有做限制.提交后还可以继续点击,造成了在短时间内的多次请求.查看日志两次错误在200ms之内. 错误信息 system.Data.Entity.Infrastructure.DbUpdate ...

  4. ef添加数据时出错 System.Data.Entity.Infrastructure.DbUpdateConcurrencyException”类型的异常

    找半天才找到 ef添加数据时出错原因:数据库表中没有主键 ,就算表中有自增列 Added方法也会报错: -        this._db.SaveChanges() “this._db.SaveCh ...

  5. .net mvc System.Web.Optimization 、System.Data.Entity.Infrastructure找不到

    在MVC4的开发中,如果在App_Start目录下BundleConfig.cs类没有找不到引用System.Web.Optimization,可以使用程序包管理控制台进行安装到使用的项目 打开 工具 ...

  6. Mysql EF 触发器生成主键id 存储区更新、插入或删除语句影响到了意外的行数(0)。实体在加载后可能被修改或删除。刷新 ObjectStateManager 项 ;System.Data.Entity.Infrastructure.DbUpdateConcurrencyException

    http://stackoverflow.com/questions/24725261/how-to-use-a-custom-identity-column-in-sql-with-entity-f ...

  7. 报错:System.Data.Entity.Infrastructure.DbUpdateException 更新条目时出错

    背景 往数据库添加数据,前端验证通过的情况下,提交报错,程序停在了SaveChanges()这行,并报如上错误. 分析 猜想是提交的领域模型不符合数据库要求,但不知道具体哪里出错.网上查资料,有人发现 ...

  8. 【model模型传入view的数据类型错误】传入字典的模型项的类型为“System.Data.Entity.Infrastructure.DbQuery`1[MapScience.PovertyAlleviation.Web.Models.Qu

    出现这个问题的原因是控制器中传给view的数据类型与View中设置的model类型不一致导致,比如控制器返回的IList类型的,而你在View里面model设置的是IEnumerable<> ...

  9. MVC开发中的常见错误-05-无法将类型“System.Data.Entity.Infrastructure.DbQuery<BBFJ.OA.Model.RoleInfo>”转换为“System.Collections.Generic.List<BBFJ.OA.Model.RoleInfo>”

    List<RoleInfo> roleInfoList = (List<RoleInfo>)ViewBag.AllRoles; 错误原因很明确了 ViewBag.AllRole ...

随机推荐

  1. Exchange 2010的部署

    实验拓扑: 实验准备条件:计算机基本配置的准备:DC (vbers):配置IP地址.子网掩码.网关EX (vbers2):配置IP地址.子网掩码.网关.指定DNS 域环境搭建的准备1.在计算机名为vb ...

  2. 优雅的swiper实例

    swiper实例 <!DOCTYPE html> <html lang="en"> <head> <meta name="vie ...

  3. js将时间戳转化为年月日时分秒

    export const dateFormatter = (nows) => { if (!nows) return '' var now = new Date(nows) var year = ...

  4. win7系统下MongoDB 4.0.1的安装

    环境: win7 - 64位系统 MongoDB下载地址: https://www.mongodb.com/download-center#community 版本: 4.0.1 安装步骤: 选择cu ...

  5. 缓存机制总结(JVM内置缓存机制,MyBatis和Hibernate缓存机制,Redis缓存)

    一.JVM内置缓存(值存放在JVM缓存中) 我们可以先了解一下Cookie,Session,和Cache Cookie:当你在浏览网站的时候,WEB 服务器会先送一小小资料放在你的计算机上,Cooki ...

  6. 对应关系,以及Module作用

    register 8101---10086 gateway 8201---10010 item-service 8301---8081 manage-web 4901---9001 npm start ...

  7. MySQL主备同步延迟

    今天看到mycat的日志,发现在wrapper.log中频繁warning:slave延迟23006秒 查看数据指标: show engine innodb status正常,而且slave的拷贝点在 ...

  8. 6U VPX 加固智能计算异构服务器

    6U VPX 加固智能计算异构服务器     北京太速科技有限公司在线客服:QQ:448468544 公司网站:www.orihard.com联系电话:15084122580

  9. redis数据库到mysql或mongodb数据库

    # -*- coding:utf-8 -*-# item_mongodb.py import redis import pymongo import json def main(): redis_co ...

  10. React-Redux 总结

    一.定义与功能 React-Redux 将所有组件分成两大类:UI 组件(presentational component)和容器组件(container component) 1.UI 组件特征: ...