简体   繁体   中英

Starting created service using sc.exe throws error: “[SC] StartService FAILED with error 129.”

I create the service using following commands: sc create MyService binpath= "C:\\Path\\MyDriver.sys" and the returned message is: [SC] CreateService SUCCESS , but once I want to start this service using: sc start MyService I get the error: [SC] StartService FAILED with error 129. . Have you any idea how to fix this error and start service properly? I've seen this , but there's no proper answer. Thanks in advance.

Error code 129 is ERROR_CHILD_NOT_COMPLETE (ie the application cannot be run in Win32 mode). You created a user-mode service since the default is type= own (ie SERVICE_WIN32_OWN_PROCESS when calling WinAPI CreateService ). However, you're trying to run a kernel-mode driver, which should be type= kernel (ie SERVICE_KERNEL_DRIVER ).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM