View Full Version : Can't get SAPI version to work...4.1.0
neal007
Sun 23rd Dec '01, 11:49am
I tried configuring the ISAPI use under Win2K Adv Server.
I changed the .PHP mapping to point to the php4isapi.dll, made sure there was read/exec permissions for IUSR, but I get this message:
The specified module could not be found.
I tried adding the ISAPI filter, but that made no change. Rebooted, no change, just can't get it to work. Any ideas?
JamesUS
Sun 23rd Dec '01, 12:02pm
At what point do you get that error? When you add to the ISAPI filters list or when you view a PHP page? (or indeed when you restart IIS)?
neal007
Sun 23rd Dec '01, 12:06pm
When I view a PHP page, i.e. try to go to my site
I tried with and w/o the ISAPI filter
I did do an IISRESET as well as a reboot, just doesn't work for me
JamesUS
Sun 23rd Dec '01, 3:25pm
Originally posted by neal007
I tried with and w/o the ISAPI filter
Even without the PHP Isapi filter set up it has the error? Do you have any others set up?
neal007
Sun 23rd Dec '01, 6:59pm
Yes, but I'm not sure I setup the ISAPI filter properly, however it looked straight forward. I chose to add, selected the location, and that was it, there isn't any other config is there?
Can you outline the steps and I'll try to do it your way.
Thanks!
Pingu
Mon 24th Dec '01, 1:50pm
copy php4ts.dll to \winnt\system32, and see if that did the trick
neal007
Mon 24th Dec '01, 2:42pm
I copied the DLL and TLB to the \system32 directory, so I'll give it a try.
Is the ISAPI filter even required? What if I only change the .php mapping in the configuration dialog under the Home Directory tab?
I'm not sure what ISAPI filtering even does, and I saw the note in the installation text file that says to skip the step (preferred) unless I read it wrong
Pingu
Tue 25th Dec '01, 9:32am
Hmm, well, my setup works (W2K server) and it looks like this:
Under Home Directory\Configuration\Application configuration:
Executable Path = C:\PHP\sapi\php4isapi.dll
Extension = .php
Verbs = All Verbs
Script Engine = on
Check that file exists = on (Not necessary, but nice at the cost of a little processing power)
Under ISAPI Filters:
Filter Name = PHP
Executable = C:\PHP\sapi\php4isapi.dll
Security settings:
* C:\PHP : Web Anonymous Users : Read&Execute\List Folder Contents\Read
* C:\WINNT\php.ini : Web Anonymous Users : Read
* No specific settings done for C:\WINNT\System32\php4ts.dll
Some settings in php.ini:
zlib.output_compression = Off
doc_root =
user_dir =
extension_dir = C:\PHP\extensions
If you have switched on some of the Windows Extensions, turn them all off (put a ; in front of every one). Once that works try out with some of the others you really need.
Hope this helps :)
neal007
Tue 25th Dec '01, 9:36am
Thanks for your outstanding effort, I will configure this right now! I did have some extensions on, and I did finally get the SAPI working, but I could never run MMC (IIS Virtual Root management) with the SAPI running, but I didn't configure it as detailed as you, so I'll try that right now!
Thanks!
Pingu
Tue 25th Dec '01, 10:03am
It's not as detailed as it seems :)
Don't forget to set appropiate rights (Read and Write) for the "session.save_path", "upload_tmp_dir" and "error_log" settings in your php.ini, if you use them.
And keep an eye out for strange things. The ISAPI module isn't stable yet. If some things don't work, or if memory usage pops through the roof, switch to CGI. That's a bit slower, but also more stable.
And you couldn't run MMC with the ISAPI running? I struggled with the right settings in the beginning, but I've always been able to run MMC. I find it hard to comprehend why the Console itself should depend on a .dll setting from IIS :confused:
You better check the Event Viewer for the why to this thing
neal007
Tue 25th Dec '01, 10:12am
I configured it all as you said, and again, my MMC won't open. I wonder if one of the snap-ins I have loaded is conflicting?
I haven't had any memory problems or errors showing in the event log.
When running in CGI mode, I sometimes get a dialog popup that I see when I terminal in with VNC that says "C:\PHP\PHP.EXE application failed to initialize..." but the forums never stop working, it just isn't initializing properly sometimes!
Well, I guess I'll switch back to CGI mode if I can't get my MMC to open with ISAPI running.
Thanks again!
Pingu
Tue 25th Dec '01, 10:57am
Bummer :(
Well, to open a clean MMC, Click Start/Run and type MMC
Click Console
Click Add/Remove Snap-In
In the Window that opens, click Add...
Select Internet Information Services and click Add
Then Close and OK.
Now you have a console running with just the IIS thing and no other snap-ins, so no conflicts. But I must admit that I am rather interested into why MMC crashes when the php ISAPI is loaded. If there are any .tmp files in your temp dir, remove them.
And from what I read, PHP doesn't fail all the time. If you are running other scripts besides the forum, then maybe one of them is doing the evil thingy. And if it's one of the forum's scripts then I would like to know definitely, hehe
neal007
Tue 25th Dec '01, 11:05am
I did just that, yes MMC runs, but it's the IIS Virtual Root snap-in that won't.
I tried exactly as you said, I opened a new MMC, just added the one snap-in, and it added, but the IIS virtual directory tree would not expand, it just locked up. I do an IISRESET and it works, until it locks up again.
Nothing else conflicting that I can tell, I'm not running anything cosmic.
Oh well! A shame, ISAPI does seem to run faster and cleaner! I hate CGI! :)
Pingu
Tue 25th Dec '01, 12:29pm
Big big bummer :(
CGI isn't as fast, but at least it's more stable. Maybe you can speed things up a little with Zend's optimizer thingy. You can find it here (it's a free download, but be sure to get the right one for PHP4.1.0):
http://www.zend.com
You'll need to add something like this to php.ini, but just read the doccumentation:
[ZendOptimizer]
zend_optimizer.enable_loader=0
zend_extension_ts="c:\path\to\ZendOptimizer.dll"
zend_optimizer.optimization_level=15
vBulletin® v3.8.0 Beta 4, Copyright ©2000-2008, Jelsoft Enterprises Ltd.