Artykuł

Exchange 2013 Upgrade – Service ‚WMSVC’ failed to reach status ‚Running’ on this server

One of the quarterly tasks that every Exchange administrator should do is to install new Cumulative Update for their Exchange 2013 server. While most of the time such upgrades are painless sometimes you reach a problem.  In our case Microsoft.Exchange.Configuration.Tasks.ServiceDidNotReachStatusException: Service ‚WMSVC’ failed to reach status ‚Running’ on this server. was enough to stop us for even trying an upgrade.

Problem description

During Readiness Checks for Microsoft Exchange Server 2013 Cumulative Update 9 (CU9) installator decided that it cannot start a service.

ExchangeCU9-Upgrade-Error1

 

Full error message looks like below:

The following error was generated when „$error.Clear();

          $keyPath = „HKLM:\Software\Microsoft\WebManagement\Server”;

          if (!(Get-Item $keyPath -ErrorAction SilentlyContinue))

          {

            New-Item $keyPath -Force

          }

          Set-ItemProperty -path $keyPath -name „EnableRemoteManagement” -value 0x1 -Type DWORD -Force;

          if (Get-Service WMSVC* | ?{$_.Name -eq ‚WMSVC’})

          {

            Set-Service WMSVC -StartupType Automatic

            Stop-SetupService -ServiceName WMSVC;

            Start-SetupService -ServiceName WMSVC

          }

        ” was run: „Microsoft.Exchange.Configuration.Tasks.ServiceDidNotReachStatusException: Service ‚WMSVC’ failed to reach status ‚Running’ on this server.

   at Microsoft.Exchange.Configuration.Tasks.Task.ThrowError(Exception exception, ErrorCategory errorCategory, Object target, String helpUrl)

   at Microsoft.Exchange.Configuration.Tasks.Task.WriteError(Exception exception, ErrorCategory category, Object target)

   at Microsoft.Exchange.Management.Tasks.ManageSetupService.WaitForServiceStatus(ServiceController serviceController, ServiceControllerStatus status, Unlimited1 maximumWaitTime, Boolean ignoreFailures, Boolean sendWatsonReportForHungService)

   at Microsoft.Exchange.Management.Tasks.ManageSetupService.StartService(ServiceController serviceController, Boolean ignoreServiceStartTimeout, Boolean failIfServiceNotInstalled, Unlimited1 maximumWaitTime, String[] serviceParameters)

   at Microsoft.Exchange.Management.Tasks.ManageSetupService.StartService(String serviceName, Boolean ignoreServiceStartTimeout, Boolean failIfServiceNotInstalled, Unlimited`1 maximumWaitTime, String[] serviceParameters)

   at Microsoft.Exchange.Management.Tasks.StartSetupService.InternalProcessRecord()

   at Microsoft.Exchange.Configuration.Tasks.Task.b__b()

   at Microsoft.Exchange.Configuration.Tasks.Task.InvokeRetryableFunc(String funcName, Action func, Boolean terminatePipelineIfFailed)”.

After a quick look at services console (services.mscWeb Management Service  was indeed down.

ExchangeCU9-Upgrade-Error3

Starting it up just brought another, a bit meaningless error

ExchangeCU9-Upgrade-Error2

Checking Event Logs / Services shows Event ID 7024 from Service Control Manager with error message:

The Web Management Service service terminated with the following service-specific error: Unspecified error

So how to fix this error? It turns out the service requires an SSL Certificate to be available in IIS. Unfortunately one of the administrators setting up certificates wanted to have „clean” certificates Window, and since certificate in Exchange ECP looks unused there's nothing stopping you to delete it. Quick look at new installation of Exchange 2013 at certificates window shows WMSVC certificate.

Exchange-CU9-ECP-Proper-Look-Fixed

And in comparison the supposedly cleaner version without the WMSVC certificate.

Exchange-CU9-ECP-Missing-Cert-Fixed

Even though the Assigned Services for this certificate are NONE Exchange Administrators should left this certificate as is. Fortunately if you've already deleted the certificate you can quickly fix it.

How to fix the problem

To resolve the problem, you must assign a new SSL certificate to the IIS Web Management Service.

Go to IIS – > Click on your Server -> Click on Management Service

Exchange-CU9-IIS-Step1-FixedUnder SSL Certificate, select the new one. (You can use a existing certificate or recreate a new self-sign with IIS). As you can see on below screenshot it clearly states there's an error with the service.

Exchange-CU9-IIS-Step2-Fixed

After choosing proper SSL Certificate and clicking Apply everything goes back to normal

Exchange-CU9-IIS-Step3-Fixed

Service can be started

Exchange-CU9-IIS-Step4

Readiness Checks go smoothly

Exchange-CU9-IIS-Step5

And we're good to go!

If things didn't work

If things didn't went as smoothly you may want to go the long road, but it's a bit untested and risky territory so do it on your own risk.

Open command prompt as Administrator
dism /online /enable-feature /featurename:IIS-WebServerRole
dism /online /enable-feature /featurename:IIS-WebServerManagementTools
dism /online /enable-feature /featurename:IIS-ManagementService
Reg Add HKLM\Software\Microsoft\WebManagement\Server /V EnableRemoteManagement /T REG_DWORD /D 1

Those 4 commands essentially make sure that all IIS roles are installed properly. Then execute:
net start wmsvc
sc config wmsvc start=auto

Then open IIS Manager and do the steps from above again.

Tags: , , ,

This is a unique website which will require a more modern browser to work! Please upgrade today!