GugaJEDI
GugaJEDI

Reputation: 33

Disable PHP 5.6.36 Thread Safe

I am compiling PHP 5.6.36 with Apache 2.4.33 on a CentOS 7 Server and the PHP Thread Safe is always enabled. I did try to compile using --disable-posix-threads but this option is not a "configure" option and also with --disable-maintainer-zts and at the end the TS is still enabled on my Server.

When I was using Apache 2.2 I didn't had this problem, once my server need to have PHP always disabled. My Zend library is compiled without TS and I will run PHP as module and not as cgi or fast-cgi.

Is there any way to compile PHP 5.6 with Apache 2.4 without TS enabled?

Upvotes: 1

Views: 1122

Answers (1)

IanB
IanB

Reputation: 2694

Apache 2.4.33 compiles using worker MPM by default which is multi threaded. When you compile PHP against a multi threaded MPM it will be thread safe enabled.

The solution is to compile Apache with --with-mpm=prefork which is single threaded. PHP compiled against that will have thread safe disabled.

Upvotes: 1

Related Questions