The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Advice needed: rookie VPS owner with needs for PHP optimization

Discussion in 'General Discussion' started by ozione, Apr 4, 2013.

  1. ozione

    ozione Member

    Joined:
    Mar 26, 2013
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hello!

    After hours of reading through these forums and googling about it, thinking and reading it all over again, I've came to conclusion I just need to ask you guys. I'm very new in the WHM waters but i think I can make sense of things pretty quickly. After running the VPS for a month or so now, I'm noticing lots of load spikes and thus I went for some optimization guides / techniques.

    Situation: at the moment I'm hosting a few websites; some are Wordpress, some are static not a big deal any of them. But I do also host vBulletin CMS with forums. VB was a reason to go for the VPS in the first place. Although I provide hosting to other websites I manage everything for everyone. No one else does anything for themselves. Just to note that.

    It's very obvious that VB is the main drain factor here and in the optimization phase, I've come to the point of PHP caching. And this is what troubles me now. VPS came preconfigured with:
    It also had "xcache" enabled.

    I grabbed VB Optimise plugin to help me with caching VB and I've found out that PHP caching isn't really compatible with my current configuration. I need to make some changes.

    I do think that my best option (from the resources perspective) would be PHP handler DSO + ruid2 but there are lots of reading on this matter and I can't quite decide what to use. I don't want to jeopard the security of the system but I do need to make it faster. I guess the mentioned configuration is indeed the best option in the meaning of performance/security factors? I also need to make sure some simple PHP scripts continue to work further (like small emailing scripts, uploading, etc...).

    If I'm on the right track with the DSO + ruid2 config:
    How would I need to approach things?
    What would I need to check / test after switching to new config?
    What should be aware of and any other hints a newbie should notice and should be able to take care of?

    I'd be grateful for any comments.
    Thank you.
     
  2. ozione

    ozione Member

    Joined:
    Mar 26, 2013
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    C'mon guys :)
    Help me out. I need to make a turn.
     
  3. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,448
    Likes Received:
    195
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    What do you mean by this exactly?

    If you're looking for ways to better optimize your server for the vBulletin forum specifically, there is no better place for that than here:
    Server Configuration - vBulletin Forums (Members Only)
     
  4. ozione

    ozione Member

    Joined:
    Mar 26, 2013
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    What I meant was, that before moving to VPS I didn't really do much for VB optimization. I was sure that the lag was coming from shared host. After moving to VPS I expected miracles but all I found was, that I was more naive than I should be.

    Anyways, I went for a few optimization guides found on the internet and VB's forums. I came to the point of caching and now I'm having problems with configuration like I stated earlier.

    From my point of understanding PHP handlers can be crucial for the performance not only VB but PHP globally. So. This is where I'm stuck. I'd like to change my config but I'm not sure what should I do and which config should I choose.

    Thanks!
     
  5. storminternet

    storminternet Well-Known Member

    Joined:
    Nov 2, 2011
    Messages:
    462
    Likes Received:
    0
    Trophy Points:
    16
    cPanel Access Level:
    Root Administrator
    I suggest you to check your vb forum database if that is using more resources. Please check the Show MySQL Processes
     
  6. ozione

    ozione Member

    Joined:
    Mar 26, 2013
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Nothing much going on here...

    Can someone tell me if there in fact is something needed to be done on the PHP side (handler and stuff)?
    :)
     
  7. hgrg

    hgrg Well-Known Member

    Joined:
    Oct 4, 2010
    Messages:
    90
    Likes Received:
    0
    Trophy Points:
    6
    cPanel Access Level:
    Root Administrator
    i suggest if you have enough memory then check out varnish as a reverse proxy cache, if you dont, then nginx as a reverse proxy for serving static content. right now im using varnish to cache wordpress based sites and its really good: i was using siege to simulate users on the site and before installing varnish the max i could get was 600 concurrent connections. with varnish now its up to 1700.. of course a cache means you've got to store it somewhere you can get fast (for me its a 4G memory cache) so its also not giving a hard time on the crappy disks ive got in the dedi :)
     
  8. ozione

    ozione Member

    Joined:
    Mar 26, 2013
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    thanks for that tip. although i need to enable something like "xcache", "apc" or "memcache". it's far best for vbulletin and some plugins that uses any of these to perform caching.

    i think i'll just need to switch hanlders so i'll be able to properly enable, for an example "apc", which seems to be the most recommended for my needs (vbulletin sources).
     
Loading...

Share This Page