[Info-vax] Apache + mod_php performance
Arne Vajhøj
arne at vajhoej.dk
Thu Sep 26 10:55:00 EDT 2024
On 9/26/2024 10:44 AM, Craig A. Berry wrote:
> On 9/25/24 4:17 PM, Arne Vajhøj wrote:
>> On 9/25/2024 5:10 PM, Arne Vajhøj wrote:
>>> Apache on VMS is prefork MPM. Yuck.
>>
>> Which puzzles me.
>>
>> VMS is a threading OS not a forking OS.
>
> Preforking in Apache just means it creates subprocesses at start-up
> time. Whoever invented the term apparently thought fork() was the only
> way to create a subprocess. On VMS it will obviously use LIB$SPAWN or
> SYS$CREPRC.
Yes. But they behave different from fork.
>> And prefork MPM is really an early 90's traditional Unix design.
>>
>> Using worker MPM on VMS would make more sense IMHO.
>
> That requires everything running in each MPM process to be thread-safe.
> It also probably doesn't provide the scaling advantages on VMS that it
> would on unixen because there is no pthread_sigsetmask: all signals are
> delivered in the main thread. Which means that somewhere around where
> threads could provide a scaling advantage, the main thread will get
> saturated and the advantage disappears. This based on the assumption
> that signals would be used for things like asynchronous I/O completion;
> I don't really know that for sure, but it seems like a pretty safe
> assumption.
Well - the threaded PHP engine that does run on VMS (Tomcat + Quercus)
performs much better, so I am optimistic. I am pretty sure that the
Java RT use standard socket IO and pthreads, so it must be possible
to achieve the same numbers in C.
>> The best would probably have been to create a VMS MPM
>> based on the WinNT MPM.
>
> And all of the Apache extensions would have to be rewritten to use QIOs
> and ASTs? That's a pretty big ask.
Why would extensions require being rewritten to use QIO's and
AST's?
Thread safe IO does not require those.
And most extensions are already available in a thread safe
version. Obviously no guarantee that it will build unchanged
on VMS, but ...
Arne
More information about the Info-vax
mailing list