logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Apache 2.2.x (ASF) faulting module errors
Author
sonofwestwood



Joined: 19 Oct 2007
Posts: 5

PostPosted: Fri 09 Nov '07 17:51    Post subject: Apache 2.2.x (ASF) faulting module errors Reply with quote

I have four servers with Apache 2.2.6 (ASF) deployed on Windows Server 2003 SP2.

Three keep reporting faulting module errors for these modules: libhttpd.dll, ntdll.dll, libapr-1.dll. Apache recovers and keeps running.

Now, the fourth server (running identical web application to one of the three) has never had these problems. It was set-up by a different person on a different network, so I wonder if any of these might explain the difference in behavior?

> Problem servers are connected to a SAN, Good server is not.

> Problem servers running W2K3 Standard Edition, Good server running Enterprise Edition

> Problem servers do have some different software installed, anything known to be particularly problematic for Apache?
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7298
Location: Germany, Next to Hamburg

PostPosted: Tue 13 Nov '07 18:31    Post subject: Reply with quote

I run successfully apache (from apache lounge) under Windows 2003 server standart edition SP 2.

Are you running different config's?
What is in your error log? Anything in Windows event log?
Back to top
sonofwestwood



Joined: 19 Oct 2007
Posts: 5

PostPosted: Tue 20 Nov '07 18:42    Post subject: Reply with quote

James Blond wrote:
Are you running different config's?


The configs are essentially the same. Apache sits on different drives and the home directories are a little different, but the same modules, etc.

James Blond wrote:
What is in your error log?


Quite often the errors appear to be related to Apache not exiting all child processes properly, either on restart or when it hits MaxRequestsPerChild. So:

> Child 2872: Terminating 5 threads that failed to exit.

> Error in my_thread_global_end(): 1 threads didn't exit

> file .\\server\\mpm\\winnt\\child.c, line 1120, assertion "(rv >= 0) && (rv < threads_created)" failed

James Blond wrote:
Anything in Windows event log?


Application log shows little more than what I posted above: Faulting application httpd.exe, version 2.2.6.0, faulting module _______ .
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7298
Location: Germany, Next to Hamburg

PostPosted: Mon 26 Nov '07 23:46    Post subject: Reply with quote

Do you use Apache from Apachelounge or apache.org?

Are there all needed files on all systems? You can check that with the depence walker

Did you change anything from the default settings about threads or childs?
Back to top
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Tue 27 Nov '07 14:35    Post subject: Reply with quote

The "Error in my_thread_global_end()" message is from MySQL.

Possibly MySQL bug 31687.

-tom-
Back to top
sonofwestwood



Joined: 19 Oct 2007
Posts: 5

PostPosted: Thu 29 Nov '07 21:17    Post subject: Reply with quote

James Blond wrote:
Do you use Apache from Apachelounge or apache.org?


From apache.org.

Quote:
Are there all needed files on all systems?


I ran DependencyWalker on httpd.exe in the Apache bin directory.

It shows DWMAPI.DLL as missing. This shows up in the tree as a dependency of c:\windows\system32\MSHTML.DLL, which looks to be part of Internet Explorer.

My "good" system also shows a missing dependency in this same part of the tree for MSJAVA.DLL. I assume the difference here is because the "good" system still has IE 6 installed, while the "bad" server has IE 7.

Would that make a difference?

Quote:
Did you change anything from the default settings about threads or childs?


I have this in my config:

ThreadsPerChild 250
MaxRequestsPerChild 1000
Back to top
Pulse77



Joined: 07 Jan 2008
Posts: 9
Location: Pretoria

PostPosted: Mon 07 Jan '08 20:56    Post subject: Solutions and more problems Reply with quote

Hi There,

I had the same problem with "Error in my_thread_global_end()" and here is what I did to solve it.

Specs:
Windows Server 2003 R2 Standard SP2
4Gb RAM
SATA RAID 5
2 x Quad Core Xeon CPUs

Software:
Apache 2.2.6 (From apache lounge)
PHP 5.2.6-DEV (from snaps.php.net)
MySQL 5.0.45
libmysql.dll from PHP 5.2.1 (This fixed the Error in my_thread_global_end() that I was getting in my apache error log)

Custom Apache Config:

Changed: EnableMMAP Off
Changed: EnableSendfile Off
Added: Win32DisableAcceptEx

Changed: MaxKeepAliveRequests 75
Changed: ThreadsPerChild 250
Changed: MaxRequestsPerChild 1024



The server seems a lot better now, but now I am also getting the errors in the eventlog:

Faulting application httpd.exe, version 2.2.6.0, faulting module libapr-1.dll, version 1.2.11.0, fault address 0x000078b5.

Our server is very active and if you check the mysql query cache hits its easy to see when the server is up or down, and on random you can see that the server is getting NO requests for about 30 seconds and gets going again.

We have a lot of CLI based PHP applications that runs on set intervals.

I am out of options, and don't know what I should be doing next to get the server from running better.

Any suggestions?
Back to top
Pulse77



Joined: 07 Jan 2008
Posts: 9
Location: Pretoria

PostPosted: Mon 07 Jan '08 21:03    Post subject: Another one Reply with quote

Just had another crash on the server, this time the error in the event log was:

Faulting application httpd.exe, version 2.2.6.0, faulting module php5ts.dll, version 5.2.5.5, fault address 0x0000acb9.

And just after the message appeared this was in the apache error log:

[Mon Jan 07 20:59:10 2008] [notice] Parent: child process exited with status 3221225477 -- Restarting.
[Mon Jan 07 20:59:10 2008] [notice] Apache/2.2.6 (Win32) PHP/5.2.6-dev configured -- resuming normal operations
[Mon Jan 07 20:59:10 2008] [notice] Server built: Sep 25 2007 20:19:40
[Mon Jan 07 20:59:10 2008] [notice] Parent: Created child process 2936
[Mon Jan 07 20:59:10 2008] [notice] Disabled use of AcceptEx() WinSock2 API
[Mon Jan 07 20:59:10 2008] [notice] Child 2936: Child process is running
[Mon Jan 07 20:59:10 2008] [notice] Child 2936: Acquired the start mutex.
[Mon Jan 07 20:59:10 2008] [notice] Child 2936: Starting 250 worker threads.
[Mon Jan 07 20:59:10 2008] [notice] Child 2936: Listening on port 80.


Which looks like a normal apache startup, but what would cause it to fail Sad

Could it be bad coding, could it be one of the CLI applications, where can I start Sad
Back to top
admin
Site Admin


Joined: 15 Oct 2005
Posts: 679

PostPosted: Mon 07 Jan '08 21:27    Post subject: Reply with quote

It's a well known issue. PHP is mostly bloating the server when PHP runs as module.

It is advised to try to run php with mod_fcgid (Fastcgi)

Running as Fastcgi memory usage of Apache is far less en the Speed is on par when running as module. There are advantages to running PHP with FCGI. Separating the PHP code from the web server removes 'bloat' from the main server, and improves the performance of non-PHP requests. Secondly, having one permanent PHP process as opposed to one per apache process means that shared resources like persistent MySQL connections are used more efficiently. And maybe even more important is stability, php is not shutting down Apache anymore.

Steffen
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7298
Location: Germany, Next to Hamburg

PostPosted: Mon 07 Jan '08 23:07    Post subject: Reply with quote

My two cents: Comment out all un needed PHP modules (extensions). IMHO they are crashing PHP and Apache, but not PHP itself. Maybe you give that a try.
Back to top
Pulse77



Joined: 07 Jan 2008
Posts: 9
Location: Pretoria

PostPosted: Wed 09 Jan '08 8:26    Post subject: Fastcgi Reply with quote

I will be trying Fastcgi, will give some feedback soon.
Back to top
funkyspider



Joined: 17 Jan 2007
Posts: 16
Location: Oldham, UK

PostPosted: Sun 24 Feb '08 15:39    Post subject: Reply with quote

sorry to resurrect an old post but has anything improved with fastcgi?

I posted about my server crashing a year ago and it still happens. All I've done is set up some software that reboots the server if it goes down. not ideal but all I could think of.

I could really do with getting this crashing problem sorted, but I really don't know what else to try.
Back to top
Steffen
Moderator


Joined: 15 Oct 2005
Posts: 3058
Location: Hilversum, NL, EU

PostPosted: Sun 24 Feb '08 22:08    Post subject: Reply with quote

Mostly php (modules) is the cause.

Ever tried Fastcgi (mod_fcgid) ?

Steffen
Back to top


Reply to topic   Topic: Apache 2.2.x (ASF) faulting module errors View previous topic :: View next topic
Post new topic   Forum Index -> Apache