FIX: IIS World Wide Web Publishing Service (W3SVC) randomly stuck by Bas Wijdenes

The SMTP Server on SERVERFQDN is unavailable.

I keep the intro short. In the summary below the post I tell you how I got to this solution.

The IIS Service occasionally stayed on Stopping.
I also installed the SMTP role on my server, which meant that the mailrelay did not work properly anymore. I saw the following error message in SCOM:

The SMTP Server on SERVERFQDN is unavailable.

In the summary below the post I tell you how I got this solution.

The SMTP Server on SERVERFQDN is unavailable.
The SMTP Server on SERVERFQDN is unavailable.

Let’s fix IIS randomly hanging on stopping.

Did you implement updates for Windows 2012 R2 in July (2018)?
Then there is in one of these updates, and unfortunately I have not found in which update, a bug that makes IIS sometimes hang on stopping.
I keep it short, Microsoft has released a hotfix for IIS hanging on stopping.

The Summary contains the following dot:

Addresses an issue that occurs when an administrator tries to stop the World Wide Web Publishing Service (W3SVC). The W3SVC remains in a “stopping” state, but cannot fully stop or it cannot be restarted.

Here is a link to the Improvements and fixes
Here a direct link to the Windows update catalog.


My Server is not a Windows 2012 R2 Server, what now?

If your Server is not a 2012 R2 server, I do not think the July 2018 updates are stopping the IIS Service W3SVC). Looking at the error message only, SCOM gives the following options as Cause and Resolutions.


Causes

A service can stop for many reasons, including:

  • The service was stopped by an administrator.
  • The service was prevented from starting because the user account could not be authenticated.
  • The service encountered an exception that stopped the service.
  • The service was improperly configured, which prevented it from starting.

Resolutions

If the IIS SMTP Server service (SMTPSVC) is not running you can diagnose the issue or restart the service by taking the following actions:

  • Check for additional service-related alerts that might have occurred concurrently. These alerts might help better identify the reason why the service entered a stopped state.
  • Review the event logs on the managed computer, and correct any underlying problems that might have caused the service to stop unexpectedly.
  • Try to restart the service.

Summary

This issue has caused some headaches at work, at some point we even temporarily used a script to restart the IIS server every morning before working hours. In the meantime I was searching was the problem was exactly.
I’ve tried everything like the Firewall, Anti-malware, and even more craziness. Until I received the same notification from another customer!
What an advantage if you work with multiple environments as a system administrator. I then changed my search to this month, and whoa! I found the solution.

Published by

Bas Wijdenes

My name is Bas Wijdenes and I work as a PowerShell Automation Engineer @ Wortell.

Leave a Reply

Your email address will not be published. Required fields are marked *