作為一個服務器維護人員,經常遇到不可解決的問題,這問題一直存在,一直困擾我多時,經常凌晨1-2點起床,就為了重啟一下進程池
錯誤應用程序名稱: w3wp.exe,版本: 7.5.7600.16385,時間戳: 0x4a5bd0eb
錯誤模塊名稱: ntdll.dll,版本: 6.1.7600.16385,時間戳: 0x4a5be02b
異常代碼: 0xc0000374
錯誤偏移量: 0x00000000000c6cd2
錯誤進程 ID: 0xb54c
錯誤應用程序啟動時間: 0x01d0c0d94f91529a
錯誤應用程序路徑: c:\windows\system32\inetsrv\w3wp.exe
錯誤模塊路徑: C:\Windows\SYSTEM32\ntdll.dll
報告 ID: 8e9b8672-2ccc-11e5-9d45-90b11c3fe265
// string method_Recycle = "Recycle"; //Start開啟 Recycle回收 Stop 停止
string method_Start = "Start";
DirectoryEntry appPool = new DirectoryEntry("IIS://localhost/W3SVC/AppPools");
try
{
foreach (DirectoryEntry item in appPool.Children)
{
string AppPoolCommand = item.Properties["ManagedPipelineMode"].Value.ToString();
string ManagedRuntimeVersion = item.Properties["ManagedRuntimeVersion"].Value.ToString();//,net版本號
string AppPoolState = item.Properties["AppPoolState"].Value.ToString();//當前狀態
if (AppPoolState != "2")
{
DirectoryEntry findPool = appPool.Children.Find(item.Name, "IIsApplicationPool");
findPool.Invoke(method_Start, null);
appPool.CommitChanges();
appPool.Close();
var IIsMsg = string.Format("[{0}],名稱:[{1}],NET版本:{2},標識:{3},當前狀態:[{4}],時間:{5}\n", "Windows2008 Server", item.Name, ManagedRuntimeVersion, item.SchemaClassName, "已啟動", DateTime.Now.ToString());
WriteText(IIsMsg);
ImportDataLog.WriteLog(item.Name, IIsMsg);
}
}
//lblCount_text.Text = i.ToString();
}
長期運行,給別人再CC攻擊多幾下都沒問題,自動啟動進程池!!