Constant Windows Handle leak with xampplite 1.6.8 on Win2K

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Constant Windows Handle leak with xampplite 1.6.8 on Win2K

Postby JStraub » 08. November 2008 00:12

When I run XAMPPLITE from www.Portableapps.com , I'm getting a constant leak of Handles at a rate of 2 per second. 1 for each apache.exe running. (For some reason, the Portable version of XAMPPLITE always runs 2 instances of apache.exe and each one takes up a truly astounding number of Handles to begin with, 30,000+ EACH!)

Now my two apache.exes are at 54,030 Handles, and 55,082 Handles and counting upwards. There is no activity on this server. It is just a test PC in my lab and I have only sent it a few most basic requests to test it out. This is so many Handles I fear it will soon exceed the built in limitations of the Windows platform and crash my system. The apache.exe process's uptime is 15 Hours right now.

I am skilled at using tools to diagnose bottlenecks and system malfunctions. Is there anything I can run to help you solve this Handle Leak? Seems like we should be able to put a logger of some type on and find out exactly what it's doing constantly once per second.... It can't be serving HTTP requests because there's no activity....

Does anyone else have this problem? You can use Windows Task Manager (View..Customize Columns) to show how many Handles each process is consuming.
Last edited by JStraub on 08. November 2008 01:59, edited 1 time in total.
JStraub
 
Posts: 2
Joined: 08. November 2008 00:05

Postby Sharley » 08. November 2008 01:46

The 2 instances of apache.exe is normal.

As for the memory leak perhaps this remedy will help:
http://www.apachefriends.org/en/faq-xam ... s.html#cpu

The added line goes at the end of the httpd.conf file.
Save the file and restart Apache.

Good luck.

BTW your link to portableapps needs the comma shifting outside the url link bracket for the link to work without issue.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3

Postby JStraub » 08. November 2008 02:03

Why does it need 2 instances, each taking up an astonishing 30,000 Handles? There must be a programming mistake to blame for all the lost handles (handles are opened but never closed). Can you verify the Handles DON'T increase at a constant rate on your system?? I shouldn't expect this to be normal behavior.

I checked that FAQ previously - it deals with 99% CPU but my issue doesn't concern the CPU at all, rather the windows "Handles" resources of the apache.exe process. The CPU% is entirely normal for me (0-3%).

BTW I didn't link the portableapps.com at all, it was an auto-link of the phpBB software but it failed to recognize the comma as grammar and auto-included it as part of the link.... I did "workaround" it now by editing the post and putting a space between the .com and the comma..
JStraub
 
Posts: 2
Joined: 08. November 2008 00:05

Postby Sharley » 08. November 2008 02:50

JStraub wrote:Why does it need 2 instances


There are always two apache.exe processes running, one of them being just a thin wrapper around the other.

Apache uses two processes as a failsafe and optimization mechanism, a parent process with a child process that handles the client requests.

I have never had your issue on my system, if I had I would have tried the FAQ fix first then started looking elsewhere and if I found nothing obvious then I would reinstall XAMPP to see if that fixes it.
If you reinstall don't overwrite but uninstall any XAMPP services and close all XAMPP components including the XAMPP Control Panel, then simply delete the XAMPP folder - check in Task Manager that all XAMPP components are gone.

Did you try adding the line that is suggested in the FAQ even, though your issue is perhaps not the CPU, by adding the line it has been known to fixed several other issues apart from the CPU?
You will never know till you try and it won't harm anything on your server or your PC.

You could try this and see if it helps:
In your httpd.conf file look for these lines round about 486 or so but may be different in your copy:
Code: Select all
# Server-pool management (MPM specific)
# Include conf/extra/httpd-mpm.conf


If the line is not commented out then add the comment so it looks like the above and try again to test the handle flow.

Save the file and restart Apache after editing but first make a backup of the conf file in case of typos.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 157 guests