Apache Websites Go Offline When Making SFTP Updates

With some regularity my websites will all go down when I'm making changes to one of them. I typically make those changes using UltraEdit saving direct to the server using SFTP. It's become common enough that I'm starting to anticipate it. Today it happened 3x over the course of a half hour. SSH and SFTP will continue to work, it's only Apache that goes down. If I reset Apache I'm back in business right away. The sites will attempt to load for some time until they timeout.

I run external monitors on the site. 99% of my failures occur when I'm working on something over SFTP. If I'm working through the CMS (Typo3 / Wordpress, etc) then I don't experience failures like this. The server is very stable when I'm not working on it.

Looking for some direction on this. Not sure how to troubleshoot. I'm fairly basic in my Linux knowledge so don't assume too much :-). I'm guessing that the problem is somewhere in the SFTP process, perhaps a memory leak of some sort? I'm not really sure how to narrow that down.

Thanks!

Versions:

Ubuntu 10.04

Apache: 2.2.14

PHP: 5.3.2

5 Replies

What do your apache and system logs show when apache goes down?

Apache log is showing some interesting things that seem to correlate with Apache going down…

[Tue Jun 03 16:02:31 2014] [notice] child pid 29160 exit signal Bus error (7)

[Tue Jun 03 16:02:31 2014] [notice] child pid 29213 exit signal Bus error (7)

[Tue Jun 03 16:02:31 2014] [notice] child pid 29214 exit signal Bus error (7)

[Tue Jun 03 16:11:23 2014] [notice] caught SIGTERM, shutting down

[Tue Jun 03 16:11:25 2014] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.17 with Suhosin-Patch mod_ssl/2.2.14 OpenSSL/0.9.8k configured – resuming normal operations

[Tue Jun 03 16:11:55 2014] [error] server reached MaxClients setting, consider raising the MaxClients setting

[Tue Jun 03 16:21:32 2014] [notice] child pid 29587 exit signal Bus error (7)

[Tue Jun 03 18:06:01 2014] [notice] child pid 30457 exit signal Bus error (7)

[Tue Jun 03 18:06:09 2014] [notice] child pid 30583 exit signal Bus error (7)

[Tue Jun 03 18:16:36 2014] [notice] caught SIGTERM, shutting down

[Tue Jun 03 18:16:37 2014] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.17 with Suhosin-Patch mod_ssl/2.2.14 OpenSSL/0.9.8k configured – resuming normal operations

[Tue Jun 03 18:16:53 2014] [error] server reached MaxClients setting, consider raising the MaxClients setting

[Tue Jun 03 18:26:05 2014] [notice] child pid 30854 exit signal Bus error (7)

[Tue Jun 03 18:26:05 2014] [notice] child pid 30931 exit signal Bus error (7)

[Tue Jun 03 18:26:05 2014] [notice] child pid 30954 exit signal Bus error (7)

[Tue Jun 03 18:26:05 2014] [notice] child pid 30960 exit signal Bus error (7)

convert: Improper image header `typo3temp/pics/8ba332e4a63dd4bee6eae4c78b267289.gif' @ gif.c/ReadGIFImage/1015.

convert: missing an image filename `typo3temp/pics/8c3ff83cbe.gif' @ convert.c/ConvertImageCommand/2838.

[Tue Jun 03 19:04:02 2014] [notice] child pid 31840 exit signal Bus error (7)

convert: Improper image header `typo3temp/pics/351fd3a7fb947e9acbf0eeefcf5a60ae.gif' @ gif.c/ReadGIFImage/1015.

convert: missing an image filename `typo3temp/pics/b6817f2ac3.gif' @ convert.c/ConvertImageCommand/2838.

convert: Improper image header `typo3temp/pics/da47b727ea17b050928b0a7edf9a84d9.gif' @ gif.c/ReadGIFImage/1015.

convert: missing an image filename `typo3temp/pics/b6817f2ac3.gif' @ convert.c/ConvertImageCommand/2838.

[Wed Jun 04 13:16:48 2014] [notice] caught SIGTERM, shutting down

[Wed Jun 04 13:16:49 2014] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.17 with Suhosin-Patch mod_ssl/2.2.14 OpenSSL/0.9.8k configured – resuming normal operations

[Wed Jun 04 13:16:59 2014] [error] server reached MaxClients setting, consider raising the MaxClients setting

convert: Improper image header `typo3temp/pics/89a42111d1c425228d9ba02401d1dec3.gif' @ gif.c/ReadGIFImage/1015.

convert: missing an image filename `typo3temp/pics/8c3ff83cbe.gif' @ convert.c/ConvertImageCommand/2838.

[Thu Jun 05 11:18:25 2014] [notice] caught SIGTERM, shutting down

[Thu Jun 05 11:18:27 2014] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.17 with Suhosin-Patch mod_ssl/2.2.14 OpenSSL/0.9.8k configured – resuming normal operations

[Thu Jun 05 11:18:32 2014] [error] server reached MaxClients setting, consider raising the MaxClients setting

[Thu Jun 05 11:43:43 2014] [notice] caught SIGTERM, shutting down

[Thu Jun 05 11:43:44 2014] [notice] Apache/2.2.14 (Ubuntu) PHP/5.3.2-1ubuntu4.17 with Suhosin-Patch mod_ssl/2.2.14 OpenSSL/0.9.8k configured – resuming normal operations

[Thu Jun 05 11:43:49 2014] [error] server reached MaxClients setting, consider raising the MaxClients setting

Syslog isn't really showing anything in that time range other than some cron activity:

Jun 5 11:17:01 localhost CRON[21426]: (root) CMD ( cd / && run-parts –report /etc/cron.hourly)

[error] server reached MaxClients setting, consider raising the MaxClients setting This looks like your issue, though I'm not sure why SFTP would trigger it. You should search through these forums for the many threads about fine tuning MaxClients.

Hitting MaxClients shouldn't cause Apache to shut down.

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