wsus微软更新服务 debug工具使用

wsus微软更新服务 debug工具使用
 
 

   用了这么久的wsus,感受它很是的娇贵,服务器上稍微有个风吹草动。立刻会提示你没法链接,或者是没法自动更新。每每最好的解决办法是重装一下wsus。此次我厌烦了重装,在之前痛苦调试的基础上,再调试一下吧。mysql

   前两天在服务器上启用了第二块网块,安装了短信平台。由于移动对短信平台出口地址有要求,因此加了一条固定路由,自己短信平台使用apache+mysql+jsp,应该是没有什么影响的。可是报错没法链接了,具体的错误web

[code]WSUS 管理控制台没法经过远程 API 链接到 WSUS 服务器。sql

请确保 Update Services 服务、IIS 和 SQL 正在该服务器上运行。若是该问题仍然存在,请尝试从新启动 IIS、SQL 和 Update Services 服务。数据库

WSUS 管理控制台遇到意外错误。这多是暂时错误;请尝试从新启动该管理控制台。若是此错误仍然存在,apache

请尝试经过删除 %appdata%\Microsoft\MMC\ 下的 wsus 文件来删除该控制台的永久性首选项。服务器


System.IO.IOException -- 因为意外的数据包格式,握手失败。app

Source
Systemfrontend

Stack Trace:
   在 System.Net.Security.SslState.StartReadFrame(Byte[] buffer, Int32 readBytes, AsyncProtocolRequest asyncRequest)
   在 System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest)
   在 System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message, AsyncProtocolRequest asyncRequest)
   在 System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32 count, AsyncProtocolRequest asyncRequest)
   在 System.Net.Security.SslState.ForceAuthentication(Boolean receiveFirst, Byte[] buffer, AsyncProtocolRequest asyncRequest)
   在 System.Net.Security.SslState.ProcessAuthentication(LazyAsyncResult lazyResult)
   在 System.Net.TlsStream.CallProcessAuthentication(Object state)
   在 System.Threading.ExecutionContext.runTryCode(Object userData)
   在 System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
   在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   在 System.Net.TlsStream.ProcessAuthentication(LazyAsyncResult result)
   在 System.Net.TlsStream.Write(Byte[] buffer, Int32 offset, Int32 size)
   在 System.Net.PooledStream.Write(Byte[] buffer, Int32 offset, Int32 size)
   在 System.Net.ConnectStream.WriteHeaders(Boolean async)
** this exception was nested inside of the following exception **jsp


System.Net.WebException -- 基础链接已经关闭: 发送时发生错误。async

Source
Microsoft.UpdateServices.Administration

Stack Trace:
   在 Microsoft.UpdateServices.Administration.AdminProxy.CreateUpdateServer(Object[] args)
   在 Microsoft.UpdateServices.Administration.AdminProxy.GetUpdateServer(String serverName, Boolean useSecureConnection, Int32 portNumber)
   在 Microsoft.UpdateServices.UI.AdminApiAccess.AdminApiTools.GetUpdateServer(String serverName, Boolean useSecureConnection, Int32 portNumber)
   在 Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.GetUpdateServer(PersistedServerSettings settings)
   在 Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.ConnectToServer()
   在 Microsoft.UpdateServices.UI.SnapIn.Scope.ServerSummaryScopeNode.get_ServerTools()[code]

       微软自己提供了一个工具,在安装目录tool里边。wsusutil.exe,主要的参数及功能以下。

checkhealth
检查服务器组件运行状态,在事件查看器应用程序栏可查看结果

configuressl
更改IIS配置后刷新注册表项

deletefrontendserver
从数据可中删除服务器记录

listinactiveapprovals
返回由于修改服务器语言设置致使不活动的批准列表

removeinactiveapprovals
删除由于服务器语言设置不当形成的不活动的更新审批

export and import
导入和导出更新元数据,用于多台WSUS之间的更新同步

healthmonitoring
在数据库中配置状态检视值


listfrontendservers
列出数据库中服务器信息

movecontent
更改WSUS服务器更新文件的储存位置。对于当前储存文件磁盘空间不足时就须要使用了。
movecontent <content path> <log file> [-skipcopy]
<content path>:内容文件的新根目录。路径必须存在。
<log file>    :要建立的日志文件的路径和文件名。
-skipcopy     :表示只应更改服务器配置,
                 不该复制内容文件。

reset
检查WSUS数据库中每一个数据元是否于本地储存的更新文件相同,若是丢失或损坏,下次连接更新服务器将从新下载更新

deleteunneededrevisions
删除不在更新的数据元,运行此命令必需要先关掉控制台和IIS站点服务

usecustomwebsite
更改wsus web服务端口80为8530,可反向操做

第二个工具wsusdebugtool.exe安装目录里没有,须要到微软的wsus主页中去下载,主要功能

wsusdebugtool.exe /tool:purgeunneededfiles
删除WSUS中已拒绝安装的补丁

wsusdebugtools.exe /tool:setforegrounddownload
不使用BITS下载更新,直接链接下载

wsusdebugtool.exe /tool:getbitsstatus
查看bits工做状态

wsusdebugtool.exe /tool:getconfiguration
查看wsus服务设置信息

WsusDebugTool.exe /Tool:GetLogs /OutputCab:c:\ServerLogs.cab
导出WSUS服务器配置及安装等日志进行DEBUG

最经常使用的就是setforgrounddownload了,能够明显提升补丁下载速度。

 

根据个人状况,本能地选择了wsusutil.exe" usecustomwebsite true.将服务端口更改一下。由原来的80改成8530,链接OK。

 检查一下IIS,发现WebSite增长了一个WSUS Administration,其目录为C:/Program File\Update Service\Webservice\Root\

修好以后我登录一看,久仰的WSUS控制台已经在链接上服务器了,你们立刻就可使用了。困扰了我一个星期的问题终于解决了,那种放松的感受真是使人难忘.

相关文章
相关标签/搜索