cannot be run because the QueueReader subsystem failed to load
阿新 • • 發佈:2018-11-22
前陣子一資料庫伺服器的事務日誌開始暴增,當時使用下面指令碼檢查發現該資料庫的log_reuse_wait_desc 一直處於REPLICATION狀態, 也就是說在事務複製過程中,與釋出相關的事務仍未傳遞到分發資料庫。剛好前一天有個同事配置了AWS的DMS相關作業。
SELECT name, log_reuse_wait_desc FROM sys.databases;
找到具體作業檢查發現,該作業的第二步出現了錯誤,LogReader服務啟動失敗了。如需截圖所示:
Message
Unable to start execution of step 2 (reason: The LogReader subsystem failed to load [see the SQLAGENT.OUT file fordetails]; The job has been suspended). The step failed.
進一步檢查SQL Server Agent的日誌輸出,發現是因為“because the QueueReader subsystem failed to load”
Date 2018/11/15 14:54:41
Log SQL Server Agent (Archive #1 - 2018/11/20 9:11:00)
Message
[LOG] Step 2 of job 'xxxx' (0xE00DFF76D02DAD47920124DD907A412D) cannot be run because the LogReader subsystem failed to load. The job has been suspended
Date 2018/11/15 14:54:44
Log SQL Server Agent (Archive #1 - 2018/11/20 9:11:00)
Message
[LOG] Step 2 of job 'xxxx' (0x1BC045267CAE2F4A8C3E283921F40641) cannot be run because the QueueReader subsystem failed to load. The job has been suspended
使用下面指令碼檢查,發現子系統QueueReader的dll是存在的,剛好同事前一天配置AWS時,在SQL Server裡面添加了Replication相關元件。而新增元件後,沒有重啟SQL Server Agent服務。重啟SQL Server Agent服務後,問題解決!
select * from msdb.dbo.syssubsystems
參考資料:
https://www.sqlservercentral.com/Forums/783200/Replication-subsystems-failed-to-load