After pressing the "Save configuration" button in administer->settings->statistics, a blank page is returned, and the Apache error log shows this:
[Fri Apr 7 14:53:21 2006] [notice] child pid 28794 exit signal Segmentation Fault (11)
Here is the version information (yeah, it's kind of old...):
Server Version: Apache/1.3.31 (Unix) DAV/1.0.3 mod_ssl/2.8.19 OpenSSL/0.9.7d PHP/4.3.10
The same thing happens in the search module too, when saving the configuration.
Comments
Comment #1
seanrSame here. In my case if I have any of image, upload, and/or urchin modules enabled, when I go to any other module's config and hit submit, I get a seg fault. The configuration options ARE saved, so the crash is happening somewhere in system_settings_form_submit after the variable_set statement. My bet is its happening in menu_rebuild();.
Comment #2
feuerri commentedThis error exists in 4.7.0-rc3 too.
Comment #3
feuerri commentedThis not only happens for the statistics and search modules but also the imap_auth module. As before the configuration is saved, but afterwards the Apache HTTPD process dies and I get a white/blank screen in the browser.
Comment #4
feuerri commentedThe symptoms are intermittent, so I'm closing my own bug report. 4.7.0 final is working well!
Comment #5
seanrReopening - it sho as **** aint working here. ;)
Comment #6
seanrMarking as critical - this is crashing two different pure core sites, no additional modules. One of the two sites I haven't even enabled any modules beyond the default few when you first install Drupal and it's already doing it. This really needs to be fixed ASAP!
Comment #7
rwelti commentedAdd me to the list of people seeing this behavior.
Only by removing or disabling Image and Image_assist does it go away.
It affects more than just the settings for the Image-related modules, for example visiting Blog-API settings and pressing Save causes the Segmentation fault (11).
I spent HOURS putting debug statements into various includes and modules, but here is the problem: if you issue too much output via "echo" it seems to interfere with the page header() mechanisms and makes it hard to know if your debug statements are themselves causing problems. I believe that if I were to attempt it again, I would use ONLY drupal_set_message or watchdog calls to log messages. That is the way to go. Also, use flush() as needed to make sure output gets output!
The long and the short of it was that it did the save to database OK and it was doing the menu_rebuild but it never got back to index.php to do the switch() statement there.
Comment #8
rwelti commentedforgot to say:
Drupal V 4.7.0 with latest Image, Img_assist as of May 9th download from drupal.org
Apache on Solaris
$ php -v
PHP 4.3.5 (cli) (built: Sep 10 2004 13:14:47)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
Comment #9
styro commentedHi guys,
I notice from the only 2 operating systems listed here are "Unix" and Solaris. Could everyone else experiencing this state what OS they are using? I don't use Unix and I'm not really in any position to fix the image module though :)
I suspect (wild guess) the problem might be a bug in the PHP GD2 (or other) library when compiled on Solaris. It would explain why most people don't notice it when the majority would use Linux.
Comment #10
rwelti commentedA bit more on my situation: first GD info, then Apache2 info, then PHP below:
Apache 2 info
Comment #11
rwelti commentedA bit more on my situation: first GD info, then Apache2 info, then PHP below:
Apache 2 info
PHP
Comment #12
rwelti commentedSorry for duplicate post above. Can't delete it like I had hoped. (And when I hit Preview I don't see see a preview!)
Anyway this could be valuable.
When I had all the debug statements in my system.module, menu.inc etc etc. I had determined that the segmentation violation occurred after set_variable (and thus database save), after menu_rebuild completion, but before returning to index.php. This is as far as I got but here is the very end of my debug statements before core dumping
Comment #13
rwelti commentedSorry for duplicate post above. Can't delete it like I had hoped. (And when I hit Preview I don't see see a preview!)
Anyway this could be valuable.
When I had all the debug statements in my system.module, menu.inc etc etc. I had determined that the segmentation violation occurred after set_variable (and thus database save), after menu_rebuild completion, but before returning to index.php. This is as far as I got but here is the very end of my debug statements before core dumping during a save (of Blog_API settings, not Image settings) :
Comment #14
killes@www.drop.org commentedI've really no idea what this is about, but since various contrib modules are involved, I am inclined to mark it "won't fix". Probably a form APi issue in these modules.
Comment #15
killes@www.drop.org commentedalso non-critical as many people apparently don't encoutner this problem.
Comment #16
seanrKilles, as I said up-thread, it was happening on one site that was pure core - no additional modules whatsoever. It actually went away after I _added_ a module, of all things. The problem is definitely in that menu_rebuild function, at least on my server. It got all the way through that function, then died after it returned but before the calling function could execute any more code. I seem to recall chx saying it sounded like a corrupt stack problem.
Comment #17
SpiesInOrbit commentedTo beat a dead horse. I have a multi-site install going and when I hit the create content > page link I get a segmentation fault. The other sites still work fine. The primary difference with this one and the others is that I set this one up rather quickly "enabled a lot of modules" all at once. Probably not the best practices method but I was in a hurry. So I will start over with a little rm -rf and do it slowly this time. More later...
Comment #18
SpiesInOrbit commentedProblem solved. Patience is a virtue. So far the rm -rf is working. For you widows folks thats deleting the directory (the cute little folder icon for the module). I guess I should not have rm -rf'd the directory (in the interest of science) however the interest of efficiency won out.
Lesson learned - set up your drupal slowly, one module at a time, followed by testing (spurious is ok).
Comment #19
seanbfuller commentedHaving similar issues with one of my installs. I can say that I probably enabled several modules at one time for this install. I tried removing my entire contrib folder, resaving the settings and modules pages, and then re-installing t he modules one-by-one. This didn't seem to do the trick as I am still having these issues. So far it is only admin pages (path_auto and video) where this is happening, so I will grin and bear it.
Additional note: We are running php4 on our dev environment. Recently we moved a site to a live environment that was running php5, and we have not seen the same issue there. I'll report back if I run into it there.
Comment #20
SpiesInOrbit commentedI have narrowed it down to this function. It has some documentation that seems to makes sense, but it could also be the problem. In drupal4.7 it is in the return of the module_implements function on line 145 of the includes/module.inc file.
here is the code for the function:
function module_implements($hook, $sort = FALSE) {
static $implementations;
if (!isset($implementations[$hook])) {
$implementations[$hook] = array();
$list = module_list(FALSE, TRUE, $sort);
foreach ($list as $module) {
if (module_hook($module, $hook)) {
$implementations[$hook][] = $module;
}
}
}
// The explicit cast forces a copy to be made. This is needed because
// $implementations[$hook] is only a reference to an element of
// $implementations and if there are nested foreaches (due to nested node
// API calls, for example), they would both manipulate the same array's
// references, which causes some modules' hooks not to be called.
// See also http://www.zend.com/zend/art/ref-count.php.
return (array)$implementations[$hook];
}
It seems to die on the return or the copy of the implements array. Beyond that I am still unaware of the cause.
I backed off some of my modules and it seems to have cleared up.
Comment #21
kamnabi commentedI faced the similar (or same?) problem when I was trying to install new modules. First, I tried to switch from PHP4 to PHP5. However, the problem still occured. Next, I increased "memory_limit" from 8M to 24M and everything goes fine now on PHP5.
There is an entry in Drupal FAQ for the problem related to the blank page:
http://drupal.org/node/31819
Comment #22
seanbfuller commentedBased on a post from kpander (http://drupal.org/node/63181#comment-177728), I tried the following hack to menu.inc, and it seems to be working so far.
In _menu_sort(), he suggested changing this:
to this:
If someone who is a bit more familiar with menu.inc could take a look to let us know the possible consequences of this hack, that would be great.
Comment #23
RobRoy commentedSean, can you include your OS, webserver name and version, and PHP version? Thanks!
Comment #24
seanbfuller commentedApache 2.0.46 (Red Hat) and PHP 4.3.11
Comment #25
morbus iffhttp://drupal.org/node/109066 is also related, and the menu reference change in _menu_sort worked for me too.
Comment #26
morbus iffAnd a patch and history for the menu.inc change: http://drupal.org/node/109074
Comment #27
Christoph C. Cemper commentedI can't believe i'm having only seg'faults after just updating ANYTHING on the new drupal server who was bought for having more performance...
I applied the menu.inc patch, but no changes !
any news on this?
PS: yes - 4.7.6 here
Comment #28
RobRoy commentedWe were just getting a bunch of segfaults on a PHP 4.6.5 install and upgraded to PHP 5.2.1 and it fixed it. Try recompiling PHP or switching versions. This is the month of PHP bugs after all! http://www.php-security.org
Comment #29
RobRoy commentedI meant 4.4.6 not 4.6.5.
Comment #30
deatech commentedI have been having the same problem under both Drupal 4.6.11 and 4.7.5, running under php4 and it seems to have gotten worse after a recent Debian php4 security update. I finally started comparing my configuration with that of another developer on this project who didn't appear to have problems and found he didn't have the Debian "php4-apd" package installed (profiler/debugger) so I commented out the following lines:
;zend_extension=/usr/lib/php4/20050606/apd.so ; php4-apd
;apd.dumpdir=/var/log/php4-apd ; php4-apd
in /etc/php4/apache/php.ini then stopped and started apache, and all the problems went away, uncomment the lines and they return, tried this several times.
Is anyone having the problem who doesn't have this installed and turned on?
Is anyone who has this turned on not having problems?
If so, are you running Debian or something else?
It would be good to know if this is a specific problem with the Debian build, or a generic problem with this extension, or if the problem is weirder and doing this fixes the problem for me but leaves others still broken
Comment #31
deatech commentedI have been having the same problem under both Drupal 4.6.11 and 4.7.5, running under php4 and it seems to have gotten worse after a recent Debian php4 security update. I finally started comparing my configuration with that of another developer on this project who didn't appear to have problems and found he didn't have the Debian "php4-apd" package installed (profiler/debugger) so I commented out the following lines:
;zend_extension=/usr/lib/php4/20050606/apd.so ; php4-apd
;apd.dumpdir=/var/log/php4-apd ; php4-apd
in /etc/php4/apache/php.ini then stopped and started apache, and all the problems went away, uncomment the lines and they return, tried this several times.
Is anyone having the problem who doesn't have this installed and turned on?
Is anyone who has this turned on not having problems?
If so, are you running Debian or something else?
It would be good to know if this is a specific problem with the Debian build, or a generic problem with this extension, or if the problem is weirder and doing this fixes the problem for me but leaves others still broken
Comment #32
Christoph C. Cemper commented@royrob : upgrade to PHP5.2.1 worked, but this PHP version killed the authentication on Drupal 4.7x sites on same server :-(
Comment #33
styro commentedThat well known PHP 5.2 authentication issue was fixed in the 4.7.5 release. Authentication on PHP 5.2 seems to work fine since that fix.
http://drupal.org/node/93945
But seeing as you've already using Drupal 4.7.6 for security reasons, maybe it is really something else? ;)
Comment #34
pasqualleThis version is not supported. Reopen or create a new issue if the problem exists in any recent version (version equal or above Drupal 5)