简体   繁体   English

'由于'活动事务',数据库的事务日志已满 - 无法备份、放大、截断或收缩

[英]'The Transaction Log for database is full due to 'Active Transaction' - Unable to Backup, Enlarge, Truncate, or Shrink

I have a SQL Server database that keeps giving me the following error:我有一个 SQL Server 数据库,它不断给我以下错误:

Msg 9002, Level 17, State 4, Line 30 Msg 9002, Level 17, State 4, Line 30
The transaction log for database 'DSC_DW_Summary' is full due to 'ACTIVE_TRANSACTION'.由于“ACTIVE_TRANSACTION”,数据库“DSC_DW_Summary”的事务日志已满。

I can see that the log file is at 100% of "Log Space Used" despite my using Simple Recovery and 1 minute recovery time.尽管我使用了简单恢复和 1 分钟的恢复时间,但我可以看到日志文件处于“已使用日志空间”的 100%。 When I try do any of the following (suggested online as potential solutions) I get the error listed above.当我尝试执行以下任何操作(在线建议作为潜在解决方案)时,我收到上面列出的错误。

  • Increase the MaxSize of the log file增加日志文件的 MaxSize
  • Backup the database备份数据库
  • Shrink the database缩小数据库

I also don't see any running transactions when I run:我在运行时也没有看到任何正在运行的事务:

SELECT * FROM sys.dm_tran_database_transactions

or:或者:

DBCC OPENTRAN

Which gives me the result:这给了我结果:

No active open transactions.没有活动的未结交易。
DBCC execution completed. DBCC 执行完成。 If DBCC printed error messages, contact your system administrator.如果 DBCC 打印错误消息,请联系您的系统管理员。

So I'm baffled.所以我很困惑。 Somehow I'm being prevented from resolving the issue because of an "Active Transaction" but I can't find any active transactions.不知何故,由于“活动交易”,我无法解决问题,但我找不到任何活动交易。

Start with checking what is preventing your log reuse:首先检查是什么阻止了您的日志重用:

SELECT [name], [log_reuse_wait_desc] FROM [sys].[databases];

Then also issue a CHECKPOINT to try and flush the log然后也发出一个 CHECKPOINT 来尝试刷新日志

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 由于“ ACTIVE_TRANSACTION”,数据库“ tempdb”的事务日志已满 - the transaction log for database 'tempdb' is full due to 'ACTIVE_TRANSACTION 由于“ACTIVE_TRANSACTION”,数据库“tempdb”的事务日志已满 - Transaction log for database 'tempdb' is full due to 'ACTIVE_TRANSACTION 由于“ACTIVE_TRANSACTION”,数据库“tempdb”的事务日志已满 - The transaction log for database 'tempdb' is full due to 'ACTIVE_TRANSACTION' “由于'LOG_BACKUP',数据库的事务日志已满”在共享主机中 - “The transaction log for database is full due to 'LOG_BACKUP'” in a shared host 由于“LOG_BACKUP”,数据库的事务日志已满 - The transaction log for database is full due to 'LOG_BACKUP' MS SQL 日志大小不够或“由于 'active_transaction',数据库的事务日志已满”。 - MS SQL log size is not enough or "the transaction log for database is full due to 'active_transaction'." 由于活动事务,SQL Server 日志已满 - SQL Server Log full due to active transaction 由于“log_backup”/(Log)LDF 文件比(Data)MDF 大 4 倍,数据库的事务日志已满 - The transaction log for database is full due to 'log_backup' / (Log)LDF file 4 times bigger than (Data)MDF 由于“LOG_BACKUP”,数据库“test”的事务日志已满。 和 C 驱动器的可用空间问题 - The transaction log for database 'test' is full due to 'LOG_BACKUP'. and free space issue with C Drive 由于“CHECKPOINT”,数据库“master”的事务日志已满 - The transaction log for database 'master' is full due to 'CHECKPOINT'
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM