I'm new to Debian servers, (Linux VPS in general) and have a question about /usr/bin-php-cgi showing up several times as "tasks" when I run the HTOP "app."

htop screenshot

I couldn't find any information online about why there are several php-cgi tasks running. Is this normal, expected? It's a fairly optimized server, in my opinion. It's running Debian 6.0 32bit with lighttpd and php with just 21mb of ram.


  • 256mb memory is not allot, that will soon fill up when you have mysql installed and a few clients connect. I have 11 child processes running for apache. Most important is that you change your sshd port remove root login and get fail2ban installed – Lawrence Cherone Nov 4 '12 at 16:14
  • Thanks @LawrenceCherone! I don't need mysql on this server and will basically stick with what's there now -- just lighttpd and php5. – Patrick Nommensen Nov 4 '12 at 22:13

Yes, this is normal. Multiple PHP workers are set up (and if you get heavy traffic, more will usually be created as needed) so your web server can handle more than one PHP request at a time.

| improve this answer | |

I think it's normal and they are forks from the original process. I'm using lighttpd with fast-cgi and there is a variable PHP_FCGI_CHILDREN but I usually also have a lot more of processes. My variable has 10 on the right side of the equation but currently I have more then 30 processes in top.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy