troubleshooting Question

Calling php-fpm directly without using a webserver

Avatar of zattz
zattz asked on
Web Languages and StandardsLinuxWeb DevelopmentPHPWeb Servers
5 Comments1 Solution1016 ViewsLast Modified:
Hi :)

I have a php script that I run multiple threads of 24hrs a day doing background processing. Originally I would call the php script using apache with mod_php, resulting in a lot of http processes using around 200mb of ram.

I then changed my setup to call php and run the script via the command line, and I also niced command line php to the lowest cpu priority.

I am now trying to improve memory usage. Would it be possible to run php-fpm, and call that directly? I would also run php-fpm at the lowest cpu priority, and was hoping that would reduce memory usage because if I understand it correctly php-fpm would have multiple threads sharing the php memory, unlike apache prefork mod_php.

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 5 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros