Segmentation fault

2003-04-01
2003-04-07
  • rodrigo diaz

    rodrigo diaz - 2003-04-01

    I've posted this message in Bugs section too.

    When modify a php script and then I try to access via
    web the page hang.
    If I try to acess again all works again without problems.

    In apache error log appears:
    [notice] child pid 23331 exit signal Segmentation fault
    (11)

    My configuration:
    MMCache 2.3.8, MM 1.3.0, PHP 4.3.1, Apache 2.0.44

    PHP configure:
    './configure' '--with-apxs2=/usr/local/apache2/bin/apxs' '--
    with-exec-dir=/usr/bin' '--with-config-file-
    path=/usr/local/etc' '--with-zlib' '--with-bz2' '--with-gd' '--
    with-ttf' '--with-png' '--with-jpeg-dir=/usr' '--with-png-
    dir=/usr' '--with-freetype-dir=/usr' '--with-expat-dir=/usr' '--
    with-gmp' '--with-xml' '--with-pear=/usr/share/pear' '--with-
    mysql=shared' '--with-interbase=shared,/opt/interbase' '--
    with-mysql-sock=/var/lib/mysql/mysql.sock' '--with-
    pgsql=shared' '--with-ldap=shared' '--with-pspell' '--with-
    kerberos' '--enable-mbstring=all' '--disable-debug' '--
    disable-rpath' '--disable-posix' '--enable-pic' '--enable-
    discard-path' '--enable-magic-quotes' '--enable-bcmath' '--
    enable-dio' '--enable-gd-native-ttf' '--enable-sysvsem' '--
    enable-sysvshm' '--enable-track-vars' '--enable-wddx' '--
    enable-inline-optimization' '--enable-memory-limit'

    PHP ini:
    zend_extension="/usr/local/lib/php/extensions/mmcache
    .so"
    mmcache.shm_size="16"
    mmcache.cache_dir="/tmp/mmcache"
    mmcache.enable="1"
    mmcache.optimizer="1"
    mmcache.check_mtime="1"
    mmcache.debug="0"
    mmcache.filter=""

    Sorry about my english, I'm spanish
    Good work, is incredibly fast :)    

     
    • Dmitry Stogov

      Dmitry Stogov - 2003-04-03

      Please check is PHP crache on any page or only on the one.

      If PHP craches only on one script I think this is a problem in optimizer. Try to disable optimizer (mmcache.optimizer="0") or throught mmcache.php "Disable Optimizer" and "Clear". If now same file will work - this is an optimizer bug.

      If you will diside what this is an optimizer bug I will need your sources to fix MMCahce BUG.

       
    • rodrigo diaz

      rodrigo diaz - 2003-04-04

      The problem is related to the optimizer, when I disable all works fine.
      Here 3 files to reproduce the error:

      error.php:
      ------------
      <?php
      include_once('error1.php');
      include_once('error2.php');
      echo test;
      ?>

      error1.php:
      --------------
      <?php
      //error1
      ?>

      <?php

      error2.php:
      --------------
      function err($ierr)
      {
              if($ierr=='')
                 $a=2;
              else
                  $a=1;
           
              exit('end');
      }
      ?>

      Access to error.php
      The first time all works fine.
      Now modify error2 (add a comment or modify $a)

      Access to error.php
      Now you can see an error (seg. fault) in apache log.

      To repair I only need to change exit('end') by exit without string or eliminate the 'else'

      Notes:
      Some times the server is freeze and you must have to refresh the page.

      Sometimes  when I stop apache I need to do a:
      killall -9 httpd
      because the server is not stopped properly.

      Thanks for your good work

       
      • Dmitry Stogov

        Dmitry Stogov - 2003-04-07

        I hope, I fixed this bug.

        Please test it with latest version of MMCache from sourceforge CVS or wait for next release (2.3.9).

         
    • rodrigo diaz

      rodrigo diaz - 2003-04-07

      I've tested with the latest version from CVS and now all works perfectly.
      Fast and good job  :)

       

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks