14

I'm trying to disable a service in Windows 10 from the Control Panel > Administrative Tools > Services snap in.

  • Service Name: OneSyncSvc_1e21e
  • Display Name: Sync Host_1e21e
  • Description: This service synchronizes mail, contacts, calendar and various other user data. Mail and other applications dependent on this functionality will not work properly when this service is not running.
  • Path to executable: C:\WINDOWS\system32\svchost.exe -k UnistackSvcGroup
  • Startup type: Automatic (Delayed Start)

When I try to change the Startup type to Manual or Disabled and press OK, I get this message:

The parameter is incorrect.

When I try to change the Startup type to Automatic and press OK, I get this message:

The delayed auto-start flag could not be reset.

Error 87: The parameter is incorrect.

When I try to change the 'Log on as' user to a user without any privileges, I get this message:

The parameter is incorrect.

I've done some searches online and within the stack exchange network, but the error message is a pretty common one and the articles I've found seem to apply to trying to install services and/or dependencies through code. I'm just using the basic windows GUI.

Is there any way I can correct this error, disable this service, or delete it entirely?

13

I stumbled upon the same issue when trying to disable MessagingService_48ab2.

The solution for it was to look for the service in the registry.

Press start button on your keyboard, type regedit, right-click it and open as administrator.

Then navigate to:
Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\OneSyncSvc_48ab2

Double-click the "Start" 32-bit DWORD and change it's value to 4 (disabled).

2

You can also use powershell to disable the service (or any other PITA service)

Start powershell as Administration (Run as Administration) and then

Get-Service -Name OneSyncSvc | Set-Service -StartupType Disabled -Confirm:$false
3
  • This is much easier (and safer) than running regedit.
    – Joe
    Feb 6 '19 at 0:49
  • Does not work, the script executed w/o errors, but the Service Manager still shows Automatic (Delayed startup).
    – Andry
    Apr 29 '19 at 11:37
  • @Andry OneSyncSvc is a "per-user service" based on a "template" service per docs.microsoft.com/en-us/windows/application-management/…. The shown command does work to change the template service, though this presumably means that it won't take effect until the user's next login. A downside of using this method is that it requires PowerShell 7+ to undo it since the default value is AutomaticDelayedStart, which isn't supported in PowerShell 5.1 (currently preinstalled with Windows 10). Dec 15 '20 at 7:39
2

Answer by askepott is the only right one.

The other answers don't take into account the crucial "The parameter is incorrect" part of the original question: PowerShell is just a dumb shell that relays the command to the same service component that fails the OP in the first place:

> Get-Service -Name "ServiceName"" | Set-Service -StartupType Disabled -Confirm:$false
Set-Service : Service 'ServiceName (ServiceName)' cannot be configured due to the following error: The parameter
is incorrect
At line:1 char:35
+ ... ame ServiceName | Set-Service -StartupType Disabled -Confirm:$false
+                         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : PermissionDenied: (System.ServiceProcess.ServiceController:ServiceController) [Set-Servi
   ce], ServiceCommandException
    + FullyQualifiedErrorId : CouldNotSetService,Microsoft.PowerShell.Commands.SetServiceCommand

Editing the registry seems to be the only solution for botched services like this. I don't know the cause of this issue, but in my case the service seemed to be configured to run with 'Log on as', with the user password provided but an empty username. Changing it to Local System wouldn't work either due to the "The parameter is incorrect" persisting with any modification.

0

This type of service is apparently what's called a "per-user service", which is generated from a "template" service visible in this registry under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services per https://docs.microsoft.com/en-us/windows/application-management/per-user-services-in-windows.

To change both the per-user and template services simultaneously, the easiest method appears to be the PowerShell command Set-ItemProperty -Path "Registry::HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\OneSyncSvc*" -Name "Start" -Value 4 (tested in PowerShell 5.1/7.1) where 4 corresponds to the "Disabled" value in the Services app (services.msc). (2 corresponds to the "Automatic (Delayed Start)" value.)

The template service can also be changed with the PowerShell command Get-Service -Name OneSyncSvc | Set-Service -StartupType "Disabled" and undone in PowerShell 7+ with the command Get-Service -Name OneSyncSvc | Set-Service -StartupType "AutomaticDelayedStart".

You may want to take note of the default values first so that any changes made can be undone afterward by using a command like Get-ItemProperty -Path "Registry::HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\OneSyncSvc*" | Select-Object "Start".

This can also be done with the PowerShell commands Get-Service -Name OneSyncSvc | Select-Object "Name", "StartupType"; Get-Service -Name OneSyncSvc* | Select-Object "Name", "StartupType".

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.