The command sc.exe config <servicename> obj= LocalSystem
results in the following error:
The account name is invalid or does not exist, or the password is invalid for the account name specified.
I want to create batch file to change a particular service to LocalSystem but the above command does not work. I can set LocalSystem via services.msc
without problems.
Thanks.
Specifies a name of an account in which a service will run, or specifies a name of the Windows driver object in which the driver will run. The default setting is LocalSystem.
The sc.exe command comes with Windows XP and is in the system32 subdirectory of the Windows installation directory (usually either C:\windows\system32 or C:\winnt\system32). As of this writing, the Windows 2000 sc.exe is available for download at ftp://ftp.microsoft.com/reskit/win2000/sc.zip.
Reference article for the sc.exe query command, which obtains and displays information about the specified service, driver, type of service, or type of driver.
Service Control - Create, Start, Stop, Query or Delete any Windows SERVICE.
For LocalSystem an empty password must be provided:
sc.exe config <servicename> obj= LocalSystem password= ""
try this...
sc config **Myservice** obj= LocalSystem password= ""
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With