Driver Problems? Questions? Issues?
Put OSR's experience to work for you! Contact us for assistance with:
  • Creating the right design for your requirements
  • Reviewing your existing driver code
  • Analyzing driver reliability/performance issues
  • Custom training mixed with consulting and focused directly on your specific areas of interest/concern.
Check us out. OSR, the Windows driver experts.

OSR Seminars

Go Back   OSR Online Lists > ntdev
Welcome, Guest
You must login to post to this list
  Message 1 of 2  
07 Mar 18 03:52
Join Date: 22 Feb 2018
Posts To This List: 8
driver service cannot be stopped

When I try to stop the driver service by "sc stop", I got below error message. =========== C:\Temp>sc stop StorTrace [SC] ControlService FAILED 1052: The requested control is not valid for this service. =========== I have already specified the driver_unload function in the DriverEntry() as in below code. And I confirmed from the Dbg log that DriverUnload function is not get called when "sc stop" is issued. ========== // config.DriverInitFlags = WdfDriverInitNonPnpDriver; config.EvtDriverUnload = DriverUnload; status = WdfDriverCreate(DriverObject, RegistryPath, &attributes, &config, WDF_NO_HANDLE ); ========== The driver service is created by below, with ========= sc create StorTrace binPath= %SystemRoot%\System32\Drivers\StorTrace.sys type= kernel start= demand ========= Here is the service query information ========= C:\Temp>sc query StorTrace SERVICE_NAME: StorTrace TYPE : 1 KERNEL_DRIVER STATE : 4 RUNNING (STOPPABLE, NOT_PAUSABLE, IGNORES_SHUTDOWN) WIN32_EXIT_CODE : 0 (0x0) SERVICE_EXIT_CODE : 0 (0x0) CHECKPOINT : 0x0 WAIT_HINT : 0x0 ========= Does anyone know what could be the reason the driver could not be stopped?
  Message 2 of 2  
07 Mar 18 07:42
Peter Viscarola
Join Date:
Posts To This List: 6193
List Moderator
driver service cannot be stopped

You can neither start nor stop PnP filters with the Service Control Manager. You need to use an INF and Device Manager (or devcon). Peter OSR @OSRDrivers
Posting Rules  
You may not post new threads
You may not post replies
You may not post attachments
You must login to OSR Online AND be a member of the ntdev list to be able to post.

All times are GMT -5. The time now is 04:09.

Copyright ©2015, OSR Open Systems Resources, Inc.
Based on vBulletin Copyright ©2000 - 2005, Jelsoft Enterprises Ltd.
Modified under license