Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 7 of 7
  1. #1
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,483
    Member #
    425
    Liked
    2783 times
    I hate asking questions like this because they're too general and don't really have the full context, but in this case I can't provide any more than this because I'm bound by an NDA and because the end client is a registry (not a registrar...a registry).

    Basically, I'm an assistant to a project manager for a project...sort of the tech liaison between the manager and the development team. They built the site on what appears to be the CodeIgniter framework, it's hosted on a HostGator VPS and pretty much ever since that point the site's been spiking the CPU.

    At first, I thought it was bots, and there was definitely an issue there...but after some rather aggressive blocking on my part and over 60% reduction of traffic to the server, the issue still persists. So I did a bit of digging last night and took myself out of my comfort zone.

    I looked at the site and the application config and disabled persistent connections in it and (I think, but I'm not sure) enabled query caching. Those things alone knocked the CPU usage down from 100% to around 50-70%, so it's a start. The problem is that I'm not a PHP guy and I'm unfamiliar with CodeIgniter, so I don't know what else in general terms I can look at for further optimization. So that's my question...in general terms, what can I look at?
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)

  2.  

  3. #2
    Member
    Join Date
    Nov 2012
    Location
    Tampa. FL
    Posts
    59
    Member #
    33844
    Liked
    21 times
    I'm not sure if this helps (or is even what you're looking for) but:
    The next step, I would think, would be to take a close look at the scripts to see if you can reduce the amount of requests and queries. Are there any database queries where using a join could reduce the amount of queries? Are there any unnecessary ajax calls being fired?
    Of course, I'm not actually asking these questions, just giving you general things to look at.
    TheGAME1264 likes this.
    Freelance Web Developer

  4. #3
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,483
    Member #
    425
    Liked
    2783 times
    Yeah, that's pretty well what I've been doing with my pseudo-PHP knowledge. I haven't found anything that would do it yet, though.

    Thanks.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)

  5. #4
    Senior Member Webzarus's Avatar
    Join Date
    May 2011
    Location
    South Carolina Coast
    Posts
    3,322
    Member #
    27709
    Liked
    770 times
    It's on a VPS right ? Does it have a performance monitor or process monitor available to see exactly what is running ? Any Cron jobs scheduled to run batch files in the background ?

    Just not sure what you have available on your VPS control panel.

    Anything like the application pool ( on IIS ), possibly recycling processes ? Again, just don't know enough abiut PHP and what's on VPS.

  6. #5
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,483
    Member #
    425
    Liked
    2783 times
    No Cron jobs. Has a performance monitor (Parallels) and MySQL seems to be the primary offender (which would make sense given that every page requires at least one MySQL call), although I noticed late last night that the CPU on the VPS plan is really weak. So I've made a strong recommendation to upgrade...given the overall size and scope of the project, it's necessary.

    Thanks.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)

  7. #6
    Senior Member Webzarus's Avatar
    Join Date
    May 2011
    Location
    South Carolina Coast
    Posts
    3,322
    Member #
    27709
    Liked
    770 times
    How many tables on MySQL and do they have any indexes ? Sometimes when table get sizeable, and they have a lot of request, indexes on the key columns will speed up retrieve speeds of commonly searched data, also improving performance as it releases resources quicker. If you're writing a lot though you may take a hit on performance if the column is indexed, as the index table has to be rewritten every time you make a update the column.

    Indexes generally tend to speed up retrieval time on columns with lots of records... If less than 4000-5000 records, probably won't see a significant change.

    If you have a lot of pages requesting ( not writing ) the same data... Indexing might help too.

  8. #7
    Unpaid WDF Intern TheGAME1264's Avatar
    Join Date
    Dec 2002
    Location
    Not from USA
    Posts
    14,483
    Member #
    425
    Liked
    2783 times
    Just one table with about 40,000 records. I put an index on the one field it would commonly be searched by. The data isn't written to at all, so I could get away with that. Didn't make much of a difference, though, since apparently there's only a 1.13 gHz CPU. This project was previously hosted on a dedicated server, but apparently the registry didn't want to pay for another one, and there are some hardcore bot issues with this project (the ones I was talking about previously).

    At any rate, I threw my childish hissy fit and asked for more. We'll see what happens. Thanks, guys.
    If I've helped you out in any way, please pay it forward. My wife and I are walking for Autism Speaks. Please donate, and thanks.

    If someone helped you out, be sure to "Like" their post and/or help them in kind. The "Like" link is on the bottom right of each post, beside the "Share" link.

    My stuff (well, some of it): My bowling alley site | Canadian Postal Code Info (beta)


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 05:07 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com