Sometimes we accidentally use an endless loop in a WEB program such as ASP, or when testing the DLL component, it crashes. At this time, IIS stops responding. Let's continue our work. Restart the IIS service.
However, this process is still being executed and the Internet Service Manager cannot be closed. When you want to restore the inetinfo.exe or DLLHOST. EXE process, we get a Denied message. Of course, you still get this prompt if you are an administrator. You may also use net stop, but it takes longer and sometimes does not respond.
At this time, we only need to restart the computer. Can I RESTART IIS without restarting my computer?
Of course, Microsoft installed a tool named iisreset when installing IIS. You can find it in winntsystem32, which can be used in the same command line as PING. It has multiple parameters. Below are several important parameters that we have selected in this article:
/RESTART |
Start IIS |
/START |
Start IIS (if stopped) |
/STOP |
Stop IIS (if started) |
/REBOOT |
Restart your computer |
/REBOOTonERROR |
Restart your computer if you fail to stop IIS |
/NOFORCE |
Do not force IIS to stop |
/TIMEOUT: X |
After X seconds, IIS is forcibly stopped unless the/NOFORCE parameter is given. If/REBOOTonERROR is given, it restarts the computer. |
You can also run the following command in CMD:
This will save you a lot of time because you don't have to restart your computer. I suggest you use it frequently.