解決MSSQL6.5設定TempDB in RAM過大導致SQL Server無法啟動問題
因為 MSSQL 6.5 Server 出現 TempDB 空間不足的訊息,所以通知所有用戶離線並進行系統調教增加空間,然後重新啟動服務就出現下列錯誤訊息:
1 2 3 | kernel udactivate(IN_RAM): Operating system error 8(Not enough storage is available to process this command.) encountered spid1 Device activation error. The physical filename 'IN_RAM' may be incorrect spid1 crdb_tempdb: Unable to move tempdb into RAM; RAM device doesn't exist, cannot be created, or doesn't have enough space for tempdb |
慘了,踩到地雷了。因為當資料庫啟動時,如果系統設定 tempdb 是存放在 RAM 上,則 SQL Server 必須建立 temp_db Device 在可用的系統記憶體空間上,若空間不足無法建立裝置就會導致資料庫啟動失敗而得到上面的錯誤訊息。
解決方式:
1. 開啟命令列視窗(cmd.exe),並以最小的配置模式啟動SQL Server使用下列命令:
sqlservr -c -f
這時會看到命令列視窗傾印錯誤紀錄,然後看到最後一行出現:
kernel Warning: override, autoexec procedures skipped.