+ Reply to Thread
Results 1 to 5 of 5

Thread: Basic Questions, please help!

  1. #1
    Join Date
    Mar 2006
    Posts
    10

    Default Basic Questions, please help!

    I've been learning some html and very basic php as I build my site, http://memoflores.com

    Recently I've been experiencing a lot of traffic and almost every day of the week my site is down for about 15 minutes.

    I've been reading about CPU limits, PHP scripts and processes running at once, but i dont know what a process is or how many PHP scripts my site is using.

    I use rollover images for my header, does javascripts affect performance on the server?

    For my blog and podcast section I use wordpress, how many PHP scripts does wordpress uses?

    I have a forum section where I use SMF.

    How can I optimize the scripts that both wordpress and SMF use?

  2. #2

    Default

    Quote Originally Posted by memo06dic View Post
    I've been learning some html and very basic php as I build my site, http://memoflores.com

    Recently I've been experiencing a lot of traffic and almost every day of the week my site is down for about 15 minutes.

    I've been reading about CPU limits, PHP scripts and processes running at once, but i dont know what a process is or how many PHP scripts my site is using.

    I use rollover images for my header, does javascripts affect performance on the server?

    For my blog and podcast section I use wordpress, how many PHP scripts does wordpress uses?

    I have a forum section where I use SMF.

    How can I optimize the scripts that both wordpress and SMF use?
    one thing you can check on, is your error log. this is updated every time you get a CPU exceed error.

    use the file manager, and go to the "tmp" folder.
    in there you will see "cpu_exceeded_logs"

    in here, will a bunch of log files, one for every day where an error occurred. look at the logs for the day(s) where errors happened, and see what it was that caused the error, and come back and let us know

    i have heard that wordpress can use a large amount of CPU and so can cause a lot of problems in a shared environment like blue host

  3. #3
    Join Date
    Mar 2006
    Posts
    10

    Default

    part of the error log looks like this:

    Fri Aug 24 05:44:28 2007: used 0.02 seconds of cpu time for HTTP Request: www.memoflores.com : GET /foro/index.php?action=profile;u=767 HTTP/1.1
    Fri Aug 24 05:46:31 2007: used 0.38 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=32 HTTP/1.1
    Fri Aug 24 05:46:37 2007: used 0.28 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=44 HTTP/1.1
    Fri Aug 24 05:46:37 2007: used 0.30 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=42 HTTP/1.1
    Fri Aug 24 05:46:54 2007: used 0.29 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=70 HTTP/1.1
    Fri Aug 24 05:46:56 2007: used 0.29 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=74 HTTP/1.1
    Fri Aug 24 05:46:56 2007: used 0.29 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=73 HTTP/1.1
    Fri Aug 24 05:46:56 2007: used 0.28 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=74 HTTP/1.1
    Fri Aug 24 05:46:47 2007: used 0.31 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=60 HTTP/1.1
    Fri Aug 24 05:46:52 2007: used 0.29 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=67 HTTP/1.1
    Fri Aug 24 05:45:02 2007: used 0.32 seconds of cpu time for HTTP Request: memoflores.com : GET /diggnationgirls/?feed=rss2 HTTP/1.1
    Fri Aug 24 05:46:54 2007: used 0.28 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=71 HTTP/1.1
    Fri Aug 24 05:46:52 2007: used 0.30 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=69 HTTP/1.1
    Fri Aug 24 05:46:52 2007: used 0.30 seconds of cpu time for HTTP Request: memoflores.com : GET /podcast/?p=67 HTTP/1.1

  4. #4

    Default

    well, one thing, do you have any entries that are full seconds, or even many fulls seconds?

    also, there are many entries there that are .35 or so seconds. each particular entry is not very high, however, the way the CPU limit system works, is if you use 30 cpu seconds within a 60 second period of time, you will get a CPU error.

    it looks as though you are doing pod casts. those can use large amounts of CPU especially if you have a lot of people o the site at the same time.

    it seems quite possible to me that what ever your site is doing, is using too much CPU power of an extended period of time. with that said there is no exact fix. either you need to get more efficient scripts, or go to a high cpu server.

    the PHP scripts i use on my server (some are quite complected/cpu heavy) still only use about .01 cou seconds or less. which makes me think your scripts are to blame

  5. #5
    Join Date
    Mar 2006
    Posts
    10

    Default

    well, one thing, do you have any entries that are full seconds, or even many fulls seconds?
    No, all entries are about .30 sec

    Sometimes I get ~4500 hits per hour.

    Do I have an alternate solution before trying to optimize my scripts?

+ Reply to Thread

Posting Permissions

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