MaxClients reached help

I notice my site went blank and could not load. I decided to look at the apache error logs and found this:

What does it mean? How can I fix it? Thanks.

[Tue Mar 16 08:24:18 2010] [error] server reached MaxClients setting, consider raising the MaxClients setting
[Tue Mar 16 09:00:01 2010] [crit] (28)No space left on device: mod_rewrite: could not create rewrite_log_lock
Configuration Failed
[Tue Mar 16 09:02:01 2010] [crit] (28)No space left on device: mod_rewrite: could not create rewrite_log_lock
Configuration Failed

Here is my current apache2.conf

 <ifmodule mpm_worker_module="">StartServers          1
    MaxClients          100
    MinSpareThreads      5
    MaxSpareThreads     25
    ThreadsPerChild      25
    MaxRequestsPerChild  100</ifmodule> 

7 Replies

The disk where Apache mod_rewrite is trying to create its lock files is either full or not writeable by the process concerned.

How can I fix this problem?

@illusime:

How can I fix this problem?
Delete files? What does

df -h

tell you?

My website is still keep going blank. I check the apache logs and here is what I found. It doesn't shut down properly and keeps running "No space left on device: modrewrite: could not create rewritelog_lock" then hang up my website… Any fix for this?

Apache logs:

Fri Mar 19 16:52:00 2010] [error] server reached MaxClients setting, consider raising the MaxClients setting

[Fri Mar 19 16:59:23 2010] [notice] mod_fcgid: process 3796 going graceful shutdown, sending SIGTERM

[Fri Mar 19 16:59:29 2010] [notice] mod_fcgid: process /var/www/fcgi-bin.d/php5-default/php-fcgi-wrapper(3796) exit(idle timeout), terminated by calling exit(), return code: 255

[Fri Mar 19 17:00:01 2010] [warn] pid file /var/run/apache2.pid overwritten – Unclean shutdown of previous Apache run?

[Fri Mar 19 17:00:01 2010] [notice] Apache/2.2.8 (Ubuntu) mod_perl/2.0.3 Perl/v5.8.8 configured – resuming normal operations

[Fri Mar 19 17:24:50 2010] [error] server reached MaxClients setting, consider raising the MaxClients setting

[Fri Mar 19 18:00:07 2010] critNo space left on device: modrewrite: could not create rewritelog_lock

Configuration Failed

[Fri Mar 19 18:02:01 2010] critNo space left on device: modrewrite: could not create rewritelog_lock

Configuration Failed

[Fri Mar 19 18:04:01 2010] critNo space left on device: modrewrite: could not create rewritelog_lock

Configuration Failed

[Fri Mar 19 18:06:01 2010] critNo space left on device: modrewrite: could not create rewritelog_lock

Configuration Failed

@illusime:

My website is still keep going blank. I check the apache logs and here is what I found. It doesn't shut down properly and keeps running "No space left on device: modrewrite: could not create rewritelog_lock" then hang up my website… Any fix for this?
I really don't get this. Have you tried freeing up some disk space as others suggested?

Also consider either expanding that disk where you log your apache things or make these logs less verbose.

After that, you can deal with the maxclients setting.

You appear to be out of disk space somewhere. What does

df -h

tell you?

If the patient has a headache and a gushing head wound, you don't treat the headache with aspirin first…

@hoopycat:

You appear to be out of disk space somewhere. What does

df -h

tell you?

If the patient has a headache and a gushing head wound, you don't treat the headache with aspirin first…

Yeah, seriously. The MaxClients isn't a big deal, it just means a user would have to wait for a slot to open (turn down your keepalive to make this shorter), but the out of disk is a big problem. That's why one says error and the other crit. Deal with crit first.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct