Loading ...
Sorry, an error occurred while loading the content.

Troubleshooting Apache/MySQL/PHP

Expand Messages
  • Jim Tucker
    I have WordPress and Drupal running on my slug. Each of these PHP applications runs on MySQL and Apache -- WordPress for my blog and Drupal for content
    Message 1 of 10 , Jul 3, 2005
    • 0 Attachment
      I have WordPress and Drupal running on my slug. Each of these PHP
      applications runs on MySQL and Apache -- WordPress for my blog and
      Drupal for content management. They run well enough on the slug for
      most tasks, if a little bit slowly, but some tasks cause the system to
      seize up so I have to reboot.

      For example, adding a WordPress user or approving a comment that has
      been submitted for moderation will quite reliably bring Apache to its
      knees indefinitely, although I can still access the slug via SSH or
      the standard Linksys web interface (good thing, too, because that's
      the point at which I have to reboot it.)

      Here are some typical entries from the Apache error log:

      [Sun Jul 03 18:14:55 2005] [warn] pid file
      /opt/var/apache2/run/httpd.pid overwritten -- Unclean shutdown of
      previous Apache run?
      [Sun Jul 03 20:28:17 2005] [error] [client 24.80.96.64] File does not
      exist: /opt/share/www/wordpress/jim/favicon.ico

      ///// ----- five more nearly identical entries --- /////

      [Sun Jul 03 20:29:41 2005] [error] [client 24.80.96.64] File does not
      exist: /opt/share/www/wordpress/jim/favicon.ico
      [Sun Jul 03 20:33:17 2005] [warn] child process 935 still did not
      exit, sending a SIGTERM
      [Sun Jul 03 20:33:19 2005] [warn] child process 935 still did not
      exit, sending a SIGTERM
      [Sun Jul 03 20:33:21 2005] [warn] child process 935 still did not
      exit, sending a SIGTERM
      [Sun Jul 03 20:33:23 2005] [error] child process 935 still did not
      exit, sending a SIGKILL


      I have been using Drupal for only a few days, but I already see a
      similar trend. Most functions are okay on the slug, but some more
      intense operations render the slug useless as web server until I reboot.

      Here are my questions:
      1. What should I inspect for clues?
      2. What can I change to make Apache and/or MySQL and/or PHP a little
      less demanding of the slug and/or more stable?
      3. Has anyone else had similar experience with WordPress or Drupal on
      the slug?
      4. What other advice could people offer for this situation?

      Thanks in advance for any responses.
    • Josh Parsons
      Some quick suggestions: Try to figure out if there s a specific function of php that is causing lockups. Some people have reported lockups connected with
      Message 2 of 10 , Jul 4, 2005
      • 0 Attachment
        Some quick suggestions:

        Try to figure out if there's a specific function of php that is causing
        lockups. Some people have reported lockups connected with email
        functionality under php-apache. If you can track down that kind of bug and
        describe how to reproduce it, other developers can take up the fight.

        Another possibility is resource deadlocks or plain crashes caused by poor
        thread-safety in dependent libraries of php. See if your problems are
        connected with php-apache trying to execute many requests at once.

        There are lots of tweakable parameters relating to the worker MPM (found
        in /opt/etc/apache2/httpd.conf - for example number of threads for apache
        to spawn) php (found in /opt/etc/php.ini - for example execution memory
        and time limits). You could try playing with those. You could also
        installing, uninstalling, or reconfiguring eaccelerator. All of these
        affect various speed / memory tradeoffs.

        ---
        Josh Parsons
        Philosophy Department
        1238 Social Sciences and Humanities Bldg.
        University of California
        Davis, CA 95616-8673
        USA

        Please avoid sending me Word or PowerPoint attachments.
        See http://www.fsf.org/philosophy/no-word-attachments.html
      • Jim Tucker
        ... bug and ... Thanks for your reply. I don t think I can narrow it down just yet to a specific PHP function, but at least I can identify a WordPress
        Message 3 of 10 , Jul 4, 2005
        • 0 Attachment
          --- In nslu2-linux@yahoogroups.com, Josh Parsons <jbparsons@u...> wrote:
          > Try to figure out if there's a specific function of php that is causing
          > lockups. Some people have reported lockups connected with email
          > functionality under php-apache. If you can track down that kind of
          bug and
          > describe how to reproduce it, other developers can take up the fight.

          Thanks for your reply.

          I don't think I can narrow it down just yet to a specific PHP
          function, but at least I can identify a WordPress procedure that is
          guaranteed (on MY slug, anyway) to cause an endless loop requiring a
          slug reboot:

          1. Install Apache, MySQL, PHP and WordPress.

          2. Set up a WordPress blog.

          3. From the WordPress Dashboard, navigate to Users -> Authors & Users
          -> Add New User.

          4. Enter the required fields for the new user and push the "Add User"
          button.

          5. Watch the browser status indicator churn endlessly, showing
          "Loading...". Note that you can no longer access your blog at all.

          Can anyone replicate this problem on one of their slugs?
        • Mathieu Monney
          Hi ! I would like to know if it is planed to publish a package of apache and php for openslug because I have installed the unslung packae in openslug and
          Message 4 of 10 , Jul 5, 2005
          • 0 Attachment
            Hi !
            I would like to know if it is planed to publish a package of apache and
            php for openslug because I have installed the unslung packae in openslug
            and apache install itself in /opt and I dislike that !
            Thanks in advance

            Mathieu
          • Tommy B
            ... Mathieu, I don t know if you saw my other reply about OpenSlug, Apache, PHP5, ssl and Virtual Hosts. In there I mentioned I ll be trying to get that moved
            Message 5 of 10 , Jul 5, 2005
            • 0 Attachment
              Mathieu Monney wrote:

              >Hi !
              >I would like to know if it is planed to publish a package of apache and
              >php for openslug because I have installed the unslung packae in openslug
              >and apache install itself in /opt and I dislike that !
              >Thanks in advance
              >
              >
              >
              Mathieu,

              I don't know if you saw my other reply about OpenSlug, Apache, PHP5, ssl
              and Virtual Hosts. In there I mentioned I'll be trying to get that
              moved into OE. It's taken me many days to get it all built natively.
              It's a non-trivial porting effort for me due to all the complexity of
              the configuration for the different packages. However, it is pretty
              straight forward and I'm working up the full recipe. I'd like to get it
              moved to build cross, but that is even more daunting. I'm working on
              things as best I can. I've published the recipe for native compiling on
              OpenSlug and that's what I've been using to build stuff.

              A version of "file" is required to build the PHP5 .so and maybe the
              latest version of libtool. The newer version is significantly faster.
              I'm just trying my best and I"m sorry if that seems slow.

              Best Regards,

              [g2]
              Tommy B.

              >Mathieu
              >
              >
              >[ Moderator Note: All new information should be recorded in the Wiki at http://www.nslu2-linux.org ]
              >Yahoo! Groups Links
              >
              >
              >
              >
              >
              >
              >
              >
              >
            • Mathieu Monney
              Oh I m sorry ! I didn t see your messages ! So if I have understood, you have sucessfully built apache and php natively on openslug and now you are trying to
              Message 6 of 10 , Jul 5, 2005
              • 0 Attachment
                Oh I'm sorry ! I didn't see your messages !
                So if I have understood, you have sucessfully built apache and php natively on openslug and now you are trying to port them in OE, is it correct ?
                So I have to wait :-) ! It's not a problem :-) ! Thanks for all this best work !

                Mathieu

                Tommy B a écrit :
                Mathieu Monney wrote:

                >Hi !
                >I would like to know if it is planed to publish a package of apache and
                >php for openslug because I have installed the unslung packae in openslug
                >and  apache install itself in /opt and I dislike that !
                >Thanks in advance
                >

                >
                Mathieu,

                I don't know if you saw my other reply about OpenSlug, Apache, PHP5, ssl
                and Virtual Hosts.  In there I mentioned I'll be trying to get that
                moved into OE.  It's taken me many days to get it all built natively.
                It's a non-trivial porting effort for me due to all the complexity of
                the configuration for the different packages.  However, it is pretty
                straight forward and I'm working up the full recipe.  I'd like to get it
                moved to build cross, but that is even more daunting. I'm working on
                things as best I can.  I've published the recipe for native compiling on
                OpenSlug and that's what I've been using to build stuff.

                A version of "file" is required to build the PHP5 .so and maybe the
                latest version of libtool. The newer version is significantly faster.
                I'm just trying my best and I"m sorry if that seems slow.

                Best Regards,

                [g2]
                Tommy B.

                >Mathieu
                >
                >
                >[ Moderator Note: All new information should be recorded in the Wiki at http://www.nslu2-linux.org ]
                >Yahoo! Groups Links
                >
                >
                >
                >
                >
                >
                >

                >



                [ Moderator Note: All new information should be recorded in the Wiki at http://www.nslu2-linux.org ]

              • Tommy B
                ... Yes that is correct.
                Message 7 of 10 , Jul 5, 2005
                • 0 Attachment
                  Mathieu Monney wrote:

                  > Oh I'm sorry ! I didn't see your messages !
                  > So if I have understood, you have sucessfully built apache and php
                  > natively on openslug and now you are trying to port them in OE, is it
                  > correct ?

                  Yes that is correct.

                  > So I have to wait :-) ! It's not a problem :-) ! Thanks for all this
                  > best work !
                  >
                  > Mathieu
                  >
                  > Tommy B a écrit :
                  >
                  >> Mathieu Monney wrote:
                  >>
                  >> >Hi !
                  >> >I would like to know if it is planed to publish a package of apache and
                  >> >php for openslug because I have installed the unslung packae in
                  >> openslug
                  >> >and apache install itself in /opt and I dislike that !
                  >> >Thanks in advance
                  >> >
                  >> > >
                  >> Mathieu,
                  >>
                  >> I don't know if you saw my other reply about OpenSlug, Apache, PHP5, ssl
                  >> and Virtual Hosts. In there I mentioned I'll be trying to get that
                  >> moved into OE. It's taken me many days to get it all built natively.
                  >> It's a non-trivial porting effort for me due to all the complexity of
                  >> the configuration for the different packages. However, it is pretty
                  >> straight forward and I'm working up the full recipe. I'd like to get it
                  >> moved to build cross, but that is even more daunting. I'm working on
                  >> things as best I can. I've published the recipe for native compiling on
                  >> OpenSlug and that's what I've been using to build stuff.
                  >>
                  >> A version of "file" is required to build the PHP5 .so and maybe the
                  >> latest version of libtool. The newer version is significantly faster.
                  >> I'm just trying my best and I"m sorry if that seems slow.
                  >>
                  >> Best Regards,
                  >>
                  >> [g2]
                  >> Tommy B.
                  >>
                  >> >Mathieu
                  >> >
                  >> >
                  >> >[ Moderator Note: All new information should be recorded in the Wiki
                  >> at http://www.nslu2-linux.org ]
                  >> >Yahoo! Groups Links
                  >> >
                  >> >
                  >> >
                  >> >
                  >> >
                  >> >
                  >> >
                  >> > >
                  >>
                  >>
                  >>
                  >> [ Moderator Note: All new information should be recorded in the Wiki
                  >> at http://www.nslu2-linux.org ]
                  >>
                  >>
                  >> ------------------------------------------------------------------------
                  >> YAHOO! GROUPS LINKS
                  >>
                  >> * Visit your group "nslu2-linux
                  >> <http://groups.yahoo.com/group/nslu2-linux>" on the web.
                  >> * To unsubscribe from this group, send an email to:
                  >> nslu2-linux-unsubscribe@yahoogroups.com
                  >>
                  >> <mailto:nslu2-linux-unsubscribe@yahoogroups.com?subject=Unsubscribe>
                  >> * Your use of Yahoo! Groups is subject to the Yahoo!
                  >> Terms of
                  >> Service <http://docs.yahoo.com/info/terms/>.
                  >>
                  >>
                  >> ------------------------------------------------------------------------
                  >>
                  >
                • Jim Tucker
                  ... I m a bit confused. I began this thread with a question about PHP scripts hanging my slug, which got as far as message 7271, and then the thread seemed to
                  Message 8 of 10 , Jul 6, 2005
                  • 0 Attachment
                    --- In nslu2-linux@yahoogroups.com, Tommy B <gentoo@n...> wrote:
                    > Mathieu Monney wrote:
                    >
                    > > Oh I'm sorry ! I didn't see your messages !
                    > > So if I have understood, you have sucessfully built apache and php
                    > > natively on openslug and now you are trying to port them in OE, is it
                    > > correct ?
                    >
                    > Yes that is correct.


                    I'm a bit confused. I began this thread with a question about PHP
                    scripts hanging my slug, which got as far as message 7271, and then
                    the thread seemed to take a tangent into the topic of porting Apache
                    and PHP in OE (whatever that is). Are these two topics related?
                  • Tommy B
                    ... Jim sorry for the confusion. There are a couple of different Apache/PHP questions. I believe yours was for Unslung (7271 -- I m guessing here) and
                    Message 9 of 10 , Jul 6, 2005
                    • 0 Attachment
                      Jim Tucker wrote:

                      >--- In nslu2-linux@yahoogroups.com, Tommy B <gentoo@n...> wrote:
                      >
                      >
                      >>Mathieu Monney wrote:
                      >>
                      >>
                      >>
                      >>>Oh I'm sorry ! I didn't see your messages !
                      >>>So if I have understood, you have sucessfully built apache and php
                      >>>natively on openslug and now you are trying to port them in OE, is it
                      >>>correct ?
                      >>>
                      >>>
                      >>Yes that is correct.
                      >>
                      >>
                      >
                      >
                      >I'm a bit confused. I began this thread with a question about PHP
                      >scripts hanging my slug, which got as far as message 7271, and then
                      >the thread seemed to take a tangent into the topic of porting Apache
                      >and PHP in OE (whatever that is). Are these two topics related?
                      >
                      >
                      >
                      Jim sorry for the confusion. There are a couple of different Apache/PHP
                      questions. I believe yours was for Unslung (7271 -- I'm guessing here)
                      and Mathieu's (7274) is for OpenSlug.

                      Best Regards,
                      [g2]

                      >
                      >
                      >[ Moderator Note: All new information should be recorded in the Wiki at http://www.nslu2-linux.org ]
                      >Yahoo! Groups Links
                      >
                      >
                      >
                      >
                      >
                      >
                      >
                      >
                      >
                    • Jim Tucker
                      ... Apache/PHP ... here) ... Thanks for clarifying that. Can anyone duplicate the PHP WordPress problem that I reported in the following message?
                      Message 10 of 10 , Jul 6, 2005
                      • 0 Attachment
                        --- In nslu2-linux@yahoogroups.com, Tommy B <gentoo@n...> wrote:
                        > Jim sorry for the confusion. There are a couple of different
                        Apache/PHP
                        > questions. I believe yours was for Unslung (7271 -- I'm guessing
                        here)
                        > and Mathieu's (7274) is for OpenSlug.

                        Thanks for clarifying that. Can anyone duplicate the PHP WordPress
                        problem that I reported in the following message?

                        http://groups.yahoo.com/group/nslu2-linux/message/7271
                      Your message has been successfully submitted and would be delivered to recipients shortly.