Enable or disable data collection
Applies to: SQL Server
This article describes how to enable or disable data collection in SQL Server by using SQL Server Management Studio or Transact-SQL.
Permissions
Requires membership in the dc_admin or dc_operator (with EXECUTE
permission) fixed database role to execute this procedure.
Use SQL Server Management Studio
Enable the data collector
In Object Explorer, expand the Management node.
Right-click Data Collection, and then select Enable Data Collection.
Disable the data collector
In Object Explorer, expand the Management node.
Right-click Data Collection, and then select Disable Data Collection.
Use Transact-SQL
Enable the data collector
Connect to the Database Engine.
From the Standard bar, select New Query.
Copy and paste the following example into the query window and select Execute. This example uses sp_syscollector_enable_collector to enable the data collector.
USE msdb;
GO
EXEC dbo.sp_syscollector_enable_collector;
Disable the data collector
Connect to the Database Engine.
From the Standard bar, select New Query.
Copy and paste the following example into the query window and select Execute. This example uses sp_syscollector_disable_collector to disable the data collector.
USE msdb;
GO
EXEC dbo.sp_syscollector_disable_collector;