Philip Van de Vyver on SCOM and OMS

Information out of the field on Operations Manager and Operations Management Suite

MSSQL: Monitoring failed – The pipe is being closed (System Center Management Pack for SQL Server

Begin October 2016, the Management Pack for SQL server got released.

Customers were seeing a lot of alerts regarding a known WMI bug:

And AlwaysOn discovery issues, as described in the announcement post, most of them will be resolved in a next version of the Mangement Pack, as the TP version already has bug fxes for that:


This post is focusing on an issue with 4001 events with the following information in the description: “The pipe is being closed”.

At a customer I was struggling with resolving 4001 events and SCOM alerts (MSSQL: Monitoring failed, MSSQL: Monitoring warning, PowerShell script failed to run).

On a SQL 2012 Cluster I saw a continuous flow of 4001 events :

Management Group: XXX. Script: Main Module: CPUUsagePercentDataSource.ps1 Version: :

Error occured during CPU Usage for SQL Instances data source executing.


Reason: Exception calling “ReturnItems” with “0” argument(s): “The pipe is being closed. (Exception from HRESULT: 0x800700E8)”



Detailed error output: Exception calling “ReturnItems” with “0” argument(s): “The pipe is being closed. (Exception from HRESULT: 0x800700E8)”


Property UserDefaultUILanguage_CreationTime does not exist at path HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft Operations Manager\3.0\Modules\{05A3E484-9657-EE7C-1A3F-74E326AAEBFB}\S-1-5-21-1224815169-144080843-1008150880-38971\Script\XXXXXXX\Common.


The customer was using the same domain account with sysadmin permissions, configured for all profiles and distributed to all SQL 2012 Computers.
For more information visit Kevin Holmans Blog:
No issues over there.


When talking to the SQL MP team, I got following feedback:

“Some management packs are causing troubles with MonitoringHost.exe, this process is being killed by SCOM.
The script can’t return data to SCOM since the listening process has been killed, and throws a pipe-related error. “

They suggested to use a different account for all Monitoring Profiles.  (SQL Server Monitoring Account)

This solved the issue immediately.
The SQL MP team are aware of this issue and will probably try to fix this in the next version of the MP.