To stop a worker process in IIS (Internet Information Services), you can use the IIS Manager or command-line tools like appcmd
. Here are the steps for both methods:
Using IIS Manager:
Open IIS Manager: Press
Win + R
, typeinetmgr
, and press Enter to open the Internet Information Services (IIS) Manager.Select Application Pool: In the Connections pane on the left, expand your server node, and then click on "Application Pools."
Stop Worker Process: In the Application Pools pane, select the application pool that corresponds to the worker process you want to stop.
Stop the Process: In the Actions pane on the right, click on "Stop" under the "Edit Application Pool" section. This will stop the worker process associated with the selected application pool.
Using Command-Line (appcmd.exe):
Open Command Prompt: Open Command Prompt or PowerShell with administrative privileges.
Navigate to the IIS Directory: By default, the
appcmd.exe
tool is located in the%SystemRoot%\System32\inetsrv
directory. You may need to navigate to this directory in the command prompt.Stop Worker Process: To stop a worker process using
appcmd
, use the following command, replacingYourAppPoolName
with the name of the application pool you want to stop:appcmd stop apppool /apppool.name:YourAppPoolName
For example, if your application pool is named "MyAppPool," the command would be:
appcmd stop apppool /apppool.name:MyAppPool
After you've stopped the worker process using either method, the application pool associated with that worker process will no longer accept new requests, and the existing requests will complete or timeout. This can be useful for performing maintenance tasks or troubleshooting when necessary.