Page 1 of 1

Segmentation fault and Invalid opcode

Posted: Tue May 05, 2009 8:00 am
by sangaiah
Hi ,

We have upgraded the PHP 4.0 to PHP 5.1.6 and RHEL3 to RHEL5

We are getting following errors,

1. [notice] child pid 31881 exit signal Segmentation fault (11)

2. Invalid opcode 117/8/8. in XXXX.php on line 788


Please note:
These above errors are not occurring consistently.

Please help me..... How to resolve the above errors?

Thanks,
Sangaiah

Re: Segmentation fault and Invalid opcode

Posted: Tue May 05, 2009 9:38 am
by nwhiting
Segmentation fault is not a PHP error but an apache error, saying it crashed.

This is most likely caused from a hardware issue, can you post the code at line 778, something is running causing it to crash wither it is a PHP bug or an issue with your script exhausting and crashing apache

Re: Segmentation fault and Invalid opcode

Posted: Wed May 06, 2009 12:15 am
by sangaiah
This is my code.

This error is not occurring on the same line... Randomly its happening.

776 $active_locales = getLocalecodes();
777 if (!empty($active_locales))
778 {
779 foreach($active_locales as $key=>$val)
780 {
781 if ($val[country_code] == "SI")
782 {
783 $char_encode = "utf-8";
784 break;
785 }
786
787 }
788 }