Apache Running Processes – Managing your servers can streamline the performance of your team by allowing them to complete complex tasks faster. Plus, it can enable them to detect problems early on before they get out of hand and compromise your business. As a result, the risk of experiencing operational setbacks is drastically lower.
But the only way to make the most of your server management is to perform it correctly. And to help you do so, this article will share nine tips on improving your server management and fix some problem about apache-2.2, process, , , .
Ok I host a website through a VPS with 1&1 and I’m worried about running out of processes.
From Parallels they have set a hard limit of 128 numprocs I have had some problems with my website just completely stopping and throwing me an error when I hit that limit. Right now I’m at 52 numprocs (not bad).
Does Apache create a new process every time someone views my site?
So if I got 200 people viewing my site I would have 200 processes (causing the site to take a dump)?
If so is there a way around this?
BTW I’ve tried to get 1&1 to up the value but they insist I need to upgrade packages but this is dumb as can be because I am barely cracking my RAM, CPU and storage space. It is this stupid little parameter that is causing the problem.
Apache creates one child process per request to maintain a certain configurable number of servers. Its not difficult to configure, but it is a little confusing.
Also, nginx is excellent for a VPS, its very lightweight and powerful. I would recommend it.
First, your technical questions:
So my question is…Does Apache create a new process every time
someone views my site?
No, it keeps a set number of servers ready to accept new connections, and typically it has a high bound set on how many of these servers it can spawn at a time. Each of these servers is configured with a max number of requests it can serve before it kills itself.
These items are configured in the MPM configuration section of your apache config.
So if I got 200 people viewing my site I would have 200 processes
(causing the site to take a dump)?
200 concurrent requests? Yes, in that situation (and if apache is configured to allow this many connections), apache will try and spin up workers to service each of the 200 requests and you’ll run into problems.
If so is there a way around this?
Now, onto the issues you’re having with their service:
The reason that your provider is limiting your number of processes is that their “VPS” service doesn’t provide a real, actual VPS. The service they provide is more like BSD-style jails. In this situation, all guests on a specific host share a single kernel. It is for this reason that they need to limit the number of processes each guest can spin up – the host’s kernel needs to keep track of all of the processes for each guest, and limits are put in place to prevent one guest instance from negatively affecting others’ ability to spawn new processes.
I’ve tried to get 1&1 to up the value but they insist I need to
upgrade packages but this is dumb
Their limits are reasonable for the service they’re providing. If you don’t like it, then move somewhere else, to a real VPS provider – one that gives you your own OS instance. I use Linode and like them very much, but there are a ton of other options as well.