Solved

Terminate a ISAPI (dll)

Posted on 2002-05-20
6
527 Views
Last Modified: 2010-04-04
How do I Terminate a ISAPI (dll) when it is on the web?
0
Comment
Question by:delpro
6 Comments
 
LVL 8

Expert Comment

by:Cesario
ID: 7021572
Dear delpro,

In order to release the lock on a DLL, PWS must be manually stopped using the command prompt. By default, Pws.exe resides in the folder C:\Windows\System\Inetsrv.

To stop PWS, type the following command:

windows\system\inetsrv\pws.exe /stop

You can then restart PWS manually restarted from the Command Prompt by using the following command:

windows\system\inetsrv\pws.exe /start

Once PWS is stopped, this will release the ISAPI DLL. Recompile the DLL, if necessary. Once PWS restarts, it will again lock the DLL when it gets instantiated by your browser.

For IIS

At the run line, type: net stop iisadmin /y and then press Enter. This will stop all services while running the make on the DLL.

After recompiling your DLL, type: net start w3svc from the run line. Your services will be up again.

Best Regards

Cesario
0
 
LVL 14

Expert Comment

by:AvonWyss
ID: 7024685
Note that with IIS you can also choose to disable ISAPI caching, which will make the webserver unload the DLL after every request. This is great for development and testing.
0
 

Author Comment

by:delpro
ID: 7026308
Is there a way to do it in the program
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 14

Expert Comment

by:AvonWyss
ID: 7026329
There is no API for this, no. Would not really make sense anyways since ISAPI works with DLLs (librarys!) and only makes calls to the DLL when necessary; besides from this, the DLL does not "run" (unlike a normal application, or a CGI application).

The only dirty trick you could try is to somehow stop or kill the web server from within one of the entry-points of your DLL, but that's not a really good idea. Therefore, use one of the other suggested methods. For you, disabling the ISAPI DLL cache might be exactly what you want.
0
 

Accepted Solution

by:
RayNorrish earned 100 total points
ID: 7178288
Do you want to kill the isapi for the purposes of replacing/updating it?

If so, check out William Egge`s ISAPI Loader, which allows replacement of dll, even while it is in use!

http://www.eggcentric.com/

If it is not what you need, a polite email may persuade him to part with the code you need to unload your DLL programatically.
0
 

Author Comment

by:delpro
ID: 7182592
Wait for a long time for this.
Thanks
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now