How to turn off telemetry for SQL 2016
Turns out, doing this seems pretty easy. Set the following registry keys:
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\130\CustomerFeedback=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\130\EnableErrorReporting=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSAS13.TESTINSTANCE\CPE\CustomerFeedback=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSAS13.TESTINSTANCE\CPE\EnableErrorReporting=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSRS13.TESTINSTANCE\CPE\CustomerFeedback=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSRS13.TESTINSTANCE\CPE\EnableErrorReporting=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSSQL13.TESTINSTANCE\CPE\CustomerFeedback=0
HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SQL Server\MSSQL13.TESTINSTANCE\CPE\EnableErrorReporting=0
HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Microsoft SQL Server\130\CustomerFeedback=0
HKEY_LOCAL_MACHINE\Software\Wow6432Node\Microsoft\Microsoft SQL Server\130\EnableErrorReporting=0
If any of the keys don't exist, then that's OK, because you apparently didn't install that feature.
Disable the following services:
SQL Analysis Services CEIP
SQL Server CEIP service
SQL Server Integration Services CEIP service 13.0
You can also use the "Error and Usage Report Settings" app that is installed with Microsoft SQL Server 2016.
This article shows the details with pretty pictures. Might save fat-finger editing your registry. In my testing it did not require a service restart, it just worked.
Here is a Powershell script that will disable all telemetry CEIP services, and will update the registry to disable CustomerFeedback and EnableErrorReporting:
Get-Service |
Where-Object { $_.Name -like '*telemetry*' -or $_.DisplayName -like '*CEIP*' } |
ForEach-Object {
$servicename = $_.Name;
$displayname = $_.DisplayName;
Set-Service -Name $servicename -StartupType Disabled
$serviceinfo = Get-Service -Name $servicename
$startup = $serviceinfo.StartType
Write-Host "$servicename : $startup : $displayname";
}
Set-Location "HKLM:\"
$sqlentries = @( "\Software\Microsoft\Microsoft SQL Server\", "\Software\Wow6432Node\Microsoft\Microsoft SQL Server\" )
Get-ChildItem -Path $sqlentries -Recurse |
ForEach-Object {
$keypath = $_.Name
(Get-ItemProperty -Path $keypath).PSObject.Properties |
Where-Object { $_.Name -eq "CustomerFeedback" -or $_.Name -eq "EnableErrorReporting" } |
ForEach-Object {
$itemporpertyname = $_.Name
$olditemporpertyvalue = Get-ItemPropertyValue -Path $keypath -Name $itemporpertyname
Set-ItemProperty -Path $keypath -Name $itemporpertyname -Value 0
$newitemporpertyvalue = Get-ItemPropertyValue -Path $keypath -Name $itemporpertyname
Write-Host "$keypath.$itemporpertyname = $olditemporpertyvalue --> $newitemporpertyvalue"
}
}