Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Apache server crashes when logging in to application


    Apache 2.2.8
    PHP 5.2.5

    I have received a system to be doing maintenance on. It is a web application that is running on RedHat Linux. The software is a mixture of C++, PHP, Java, javascript, HTML. The application is bundled together with MySQL server/client, Apache webserver and PHP. There is no information about the pre-requisites to install this system from scratch.

    My experience is limited regarding all above except C++ and in this case my C++ knowledge doesn’t help much.

    The Linux version is to be changed to a later one in a new environment and the MySql –server is to be running on a separate machine. PHP and Apache is not to be upgraded.
    Since the application is installed in /myapp/ all functionality, MySql, PHP, Apache is located under /ada today. The new environment requires that the top directory is /opt/. This means that my system will now be located like /opt/ada/. I expected that it would be possible to just copy the /ada –directory and move it to the new environment. Changes in the defined paths in the system would be necessary of course. All paths starting with /ada/ are now changed to /opt/ada/ in the files.

    The webserver starts in the new environment and it is possible to get the login page. It looks fine but having entered user name and password and Enter it crashes.

    In the old working environment it works fine and I have used strace in both environments to see what the differences are. There are differences from the very beginning. Log snippets file attached.

    Now the questions:
    1. As mentioned above the /ada directory was copied(made a .tar-file) from the old environment and put it in the /opt directory in the new. Is this a possible way to get the system working or am I bound for problems? I mean, should I have installed php, Apache in some other way or is this way OK...?

    2. In the beginning of both logs ther is a read but it differs.
    Working environment shows "read(9, "GET /query/ HTTP/1.1\r\nAccept: im"..., 8000) = 680" while
    non-working shows "read(9, "POST /authenticate HTTP/1.1\r\nAcc"..., 8000) = 778"

    I am speculating that this difference is the root cause to the segmentation fault later on. Since it is the same code in both environments I have no idea why this differs.
    I have been thinking about that there might be some access/permission/configuration problem with Apache.
    Any ideas about what to check/do about this? Environment variables maybe?

    3. Anybody recognizing the futex in the segmentation fault and what the problem might be?

    Attached Files Attached Files

  2. #2

    Running gdb shows more information


    The continuing investigation regarding why the web server processes crashes has shown that they crash even the first time the IP-address is entered in the web-browser. The attached file with the strace snippets is then unfortunately misguiding. It seems to be working fine but there is a segmentation fault before these logs are created.

    When using gdb on all the processes it has been found that the segmentation fault occurs when the pthread_cancel-method in libpthread is called.

    More information about the system is that it has been compiled and linked in a 32-bit machine and is now running in a 64-bit machine. The libpthread used in the old environment is 2.3.4 and now it is 2.5.

    Anybody having any ideas to why these crashes occur? What to check? Is recompiling/linking in the 64-bit environment necessary? Are libpthread 2.3.4 and 2.5 not compatible or...?


  3. #3
    Just Joined! trijit's Avatar
    Join Date
    Dec 2010
    Far Far Away from Earth.....
    Could you please paste the logs?

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts