?
Solved

child pid xxxxx exit signal Segmentation fault (11)

Posted on 2005-05-15
13
Medium Priority
?
2,911 Views
Last Modified: 2012-06-27
When I submit the php form I get Cannot find server. I looked in the apache logs and I see that every time that happens I get the following error:

[notice] child pid xxxxx exit signal Segmentation fault (11)

where xxxxx is a different 5 digit number each time. What happened? Everything was working fine before with the same exact php code. I haven't changed any server configurations.

Please help!!!

Linux: Fedora Core 3
Apache: 2.0.53
PHP: 5.0.4
0
Comment
Question by:itcdr
  • 8
  • 3
  • 2
13 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 14021328
do you use mod_php?
11 - EGAIN  sounds like you have too much processes running
can yoiu please check your /var/log/messages
0
 
LVL 1

Author Comment

by:itcdr
ID: 14021713
do you use mod_php?
no

11 - EGAIN  sounds like you have too much processes running
I tried restarting the computer and the problem still occurs.

can yoiu please check your /var/log/messages

[root@web ~]# ps aux | grep httpd
root      2926  0.0  0.4 19280 9800 ?        Ss   May16   0:01 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8541  0.0  0.4 19280 9916 ?        S    11:04   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8542  0.0  0.4 19280 9920 ?        S    11:04   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8543  0.0  0.5 19432 10264 ?       S    11:04   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8544  0.0  0.4 19280 9924 ?        S    11:04   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8545  0.0  0.4 19280 9940 ?        S    11:04   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8568  0.0  0.4 19416 10160 ?       S    11:05   0:00 /usr/local/apache/bin/httpd -k start -DSSL
nobody    8569  0.0  0.4 19416 10088 ?       S    11:10   0:00 /usr/local/apache/bin/httpd -k start -DSSL

Is this normal? Could this be the reason why I'm having this problem?
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 14022224
> > do you use mod_php?
>no
then each request to a php-page starts a new process, that leads to my assumtion that the number of processes is limited

> Is this normal?
yes

What is in /var/log/messages?
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 1

Author Comment

by:itcdr
ID: 14022384
I just caused the error again and nothing came up in /var/log/messages.

Any ideas?
0
 
LVL 10

Expert Comment

by:idmisk
ID: 14048357
> When I submit the php form
and then you say

>> do you use mod_php?
>no

what kind of scripting language is it then? perl? python? i see such errors every week (our company develops large portal systems) and most of them results from bad (PHP) code. i suggest to use a debugger to find it out - that's the fastest way i know.
0
 
LVL 1

Author Comment

by:itcdr
ID: 14048442
The scripting language is php. I installed it from source from php.net. I thought mod_php is a different version from the source.

The PHP code doesn't return any errors when I run it.  In fact I can run the same code with the same input 5 times and 2 of those I would get the error and the other 3 times the code would run fine.

The only functions I'm using in this program that i've never used are for simple_xml.

How do I find the problem?
0
 
LVL 10

Accepted Solution

by:
idmisk earned 2000 total points
ID: 14048646
as i told im my prev comment, the fastest and best way i know is to debug the script execution. try
http://xdebug.org/
or
http://pecl.php.net/package/apd
0
 
LVL 1

Author Comment

by:itcdr
ID: 14048664
I'll try and see what I come up with.
0
 
LVL 1

Author Comment

by:itcdr
ID: 14048812
I found that I also get this error the first time the problem occurs:

*** glibc detected *** free(): invalid pointer: 0xfeebd614 ***


What does it mean?
0
 
LVL 10

Expert Comment

by:idmisk
ID: 14048842
it may be a bug in one of php modules. i can't really answer it, such situations must be debugged.
0
 
LVL 1

Author Comment

by:itcdr
ID: 14048843
Also I am getting a slightly different error than before:

*** glibc detected *** free(): invalid pointer: 0xfeebd614 ***
[Fri May 20 13:30:45 2005] [notice] child pid 12812 exit signal Aborted (6)

Any ideas? I'll try the debugger to see if that turns up anything.

0
 
LVL 1

Author Comment

by:itcdr
ID: 14048926
I installed xDebug and now I am getting their error instead of the apache errors.

Here is what I get:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in index.php on line 83

Line 83: if(!in_array($dom,$domains))

where:
$dom=$val['name']; //This is the value returned from the simple_xml array
$domains=$_GET['domains']; //This is the array passed from the form from the checkbox
<input name="domains[]" type="checkbox" value="val1"> val1 //Here an example of the inputs
<input name="domains[]" type="checkbox" value="val2"> val2


Good idea about installing the debugger. Now I know where the problem is. Any ideas why I'm having a problem with the $domains array?
0
 
LVL 1

Author Comment

by:itcdr
ID: 14048974
I found the problem. It turns out the problem occured whenever the $domains array was empty. To solve the problem I just added the following line:

$domains=array(); //Here is the line I added to fix the problem
$domains=$_GET['domains'];


Thanks for all your help. Who knew it would turn out to be something so stupid.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my time as an SEO for the last 2 years and in the questions I have assisted with on here I have always seen the need to redirect from non-www urls to their www versions. For instance redirecting http://domain.com (http://domain.com) to http…
Hi, in this article I'm going to teach you how to run your own site, and how to let people in (without IP). I'll talk about and explain each step... :) By the way, everything in this Tutorial is completely free and legal. This article is for …
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Are you ready to place your question in front of subject-matter experts for more timely responses? With the release of Priority Question, Premium Members, Team Accounts and Qualified Experts can now identify the emergent level of their issue, signal…
Suggested Courses
Course of the Month17 days, 12 hours left to enroll

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question