Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Load / CPU usage ?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Load / CPU usage ?

UmairUmair Member
edited January 2015 in General

Hi Guys,

This for a of VPS running cP + LSWS ... It has only one WP blog with fairly decent traffic. I moved the site form an other provider to this server yesterday. Have a look at top result.


top - 13:16:41 up 10:30,  3 users,  load average: 9.39, 9.11, 8.94
Tasks: 171 total,  11 running, 160 sleeping,   0 stopped,   0 zombie
Cpu(s): 65.6%us, 34.1%sy,  0.0%ni,  0.1%id,  0.0%wa,  0.0%hi,  0.1%si,  0.1%st
Mem:   4937872k total,  1397972k used,  3539900k free,     8256k buffers
Swap:  1048572k total,        0k used,  1048572k free,   327120k cached

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
21080 wpdummy  20   0  224m  51m  24m R 64.6  1.1   0:54.06 lsphp5:wpdummy/public_html/index.php
20648 wpdummy  20   0  224m  52m  24m R 62.3  1.1  10:20.02 lsphp5:wpdummy/public_html/index.php
20536 wpdummy  20   0  230m  58m  24m R 60.0  1.2  14:29.70 lsphp5:wpdummy/public_html/index.php
21000 wpdummy  20   0  216m  43m  24m R 60.0  0.9   1:39.98 lsphp5:wpdummy/public_html/index.php
21001 wpdummy  20   0  226m  54m  24m R 60.0  1.1   1:41.97 lsphp5:wpdummy/public_html/index.php
20665 wpdummy  20   0  220m  48m  24m R 57.3  1.0   9:37.91 lsphp5:c_html/wp-admin/admin-ajax.php
20895 wpdummy  20   0  223m  51m  24m R 56.3  1.1   4:13.47 lsphp5:wpdummy/public_html/index.php
20313 wpdummy  20   0  222m  49m  24m R 55.7  1.0  19:21.45 lsphp5:wpdummy/public_html/index.php
20558 wpdummy  20   0  225m  53m  24m R 55.3  1.1  12:35.02 lsphp5:wpdummy/public_html/index.php
20617 wpdummy  20   0  220m  47m  24m R 50.4  1.0  12:30.38 lsphp5:wpdummy/public_html/index.php
19479 nobody     1 -19  120m  10m 1244 S  4.3  0.2   2:38.75 litespeed (lshttpd)
19476 nobody     1 -19 52888 6300  556 S  0.7  0.1   0:01.62 litespeed (lshttpd)

    root@test [~/]# netstat -anp | grep :80 | wc -l
    447

I am not impressed with the performance and the load. Its been around 6-10. The LSWS and MySQL are pretty optimzed. (I have been dong this for a while now)

My question is, why high value of %sy ??
Does that mean the VPS genuinely need more CPU power ??? Or does that indicate the main node is overloaded ??

Or does it give any info at all as to why the load is that high ??

Thanks

«1

Comments

  • Quickly do a virus scan on ClamAV - It doesn't seem right at all.. - check to see if you've been rooted as well..

  • MaouniqueMaounique Host Rep, Veteran

    How many cores, what kind, what virtualization, I see no wa, no st, looks pretty ok from the node point of view.

    Thanked by 1vimalware
  • 6CPU cores, OpAPP Cloud, Xen ....
    SSD based ... Disk is pretty fast (I believe OnApp uses Cpu Priority so the cores are not dedicated here)

    What does a constant high %sy means ?? Does that mean I need to upgrade ??

  • Did the node ever crash? Reboots?

  • @century1stop said:
    Did the node ever crash? Reboots?

    Nope. I have the server for a while now but wasn't running anything on it. Moved that site on it yesterday.

    Previously that site was with a different provider running on 4Core KVM VPS ... (Interestingly both provider have same CPU Model E5-2660)

    So ideally I was expecting it to perform better. Still looking ...

  • godtorgodtor Member, Host Rep

    Is the wordpress site optimized ? From the "top" it looks like the site is eating up the CPU. What CPU values you had on the other server ?

  • Umair said: Nope. I have the server for a while now but wasn't running anything on it. Moved that site on it yesterday.

    Try putting up a monitor for this server, see how it goes. A soft reboot for E5 node will take only seconds, you probably won't notice.

    Performance depends on a lot of factors.......

  • Congrats in using wordpress.

    I hope nothing important in on it.

    Thanked by 1Hassan
  • GoodHostingGoodHosting Member
    edited January 2015

    Sadly that seems about right, although those incoming figures are high.

    #1 Does your site normally have 125-500 Concurrent visitors?

    If not, fix this problem first (you showed 500 active connections on port 80.)

    #2 Allow your lighttpd to CACHE PAGES for some time ((3-10) seconds)

    If you don't have to call PHP for every page load, you can handle MANY more requests...

    #3. If #1 and you can't do #2 , consider implementing XCache or APC

    I don't know which as WordPress doesn't really support either, and there are plugins that make use of individual caches, but http://xcache.lighttpd.net/demo/cacher/ is a very wonderful software and is updated very often, whereas APC development...

  • @godtor said:
    Is the wordpress site optimized ? From the "top" it looks like the site is eating up the CPU. What CPU values you had on the other server ?

    That was 4CPU core standard VPS (KVM based).. (same cpu model)
    The load was high there as well .. but that server was using Apache/MySQL ....

    I moved to this cloud and have switched to LiteSpeed + MariaDB. (Optimized config for both, I have been using that for a while now for other sites)

    Uped the core to 6CPU on this server... Like I said, I guess I was expecting it to perform better than this.

  • @century1stop said:
    Performance depends on a lot of factors.......

    I know ... Just wondering what more I can do here. This server is not going down. I have monitoring setup and working pretty good. The issue here is just high load .. And I will like to have it below 2 or 3.

  • @TinyTunnel_Tom said:
    Congrats in using wordpress.

    I hope nothing important in on it.

    What is that supposed to mean ?? You have something against using WP ?

  • @Umair said:
    What is that supposed to mean ?? You have something against using WP ?

    WordPress is considered bad at performance, they still don't use PDO, and the plugin code is atrocious (not something the WP authors can control per se, but not something they helped either; early skeletons and such, +closures, would have been nice.)

  • @GoodHosting said:
    Sadly that seems about right, although those incoming figures are high.

    #1 Does your site normally have 125-500 Concurrent visitors?

    If not, fix this problem first (you showed 500 active connections on port 80.)

    #2 Allow your lighttpd to CACHE PAGES for some time ((3-10) seconds)

    If you don't have to call PHP for every page load, you can handle MANY more requests...

    #3. If #1 and you can't do #2 , consider implementing XCache or APC

    I don't know which as WordPress doesn't really support either, and there are plugins that make use of individual caches, but http://xcache.lighttpd.net/demo/cacher/ is a very wonderful software and is updated very often, whereas APC development...

    Well the site is fairly active. With 100-125 Concurrent connections. (The output I gave earlier includes both established + waiting)

    I am not using Lighttpd. I am using LiteSpeed Web Server (litespeedtech.com) with eAccelerator running in DSO mode to get benefit of OpcodeCache.

    (Server is running cPanel)

  • VikingLayerVikingLayer Member
    edited January 2015

    That load does indeed seem to be very high. For comparison, this is with 1000+ concurrent connections with only 1.0-1.5 load. There's nothing fancy about the setup either, just nginx in front of apache.

    https://i.imgur.com/iu36T7L.png
    https://i.imgur.com/CuG10MJ.png

  • MunMun Member

    I'd say you need caching for wordpress

  • AshleyUkAshleyUk Member
    edited January 2015

    Due to the low I/O WA id say there is not much of an issue on the node, and by looking at the process list you have a large amount of CPU being used by PHP.

    I would look to make sure you have cache enabled within LSWS and that it is setup correctly, just becuase you have moved over to LSWS does not mean your see an improvement if something is still not setup right.

    But I would defintly say from the information we have seen, there is no issues with the Node/VPS layer but PHP is being hit hard, which with wordpress is rather common.

    Thanked by 1Maounique
  • MaouniqueMaounique Host Rep, Veteran

    @AshleyUk said:
    Due to the low I/O WA id say there is too much of an issue on the node, and by looking at the process list you have a large amount of CPU being used by PHP.

    I would look to make sure you have cache enabled within LSWS and that it is setup correctly, just becuase you have moved over to LSWS does not mean your see an improvement if something is still not setup right.

    But I would defintly say from the information we have seen, there is no issues with the Node/VPS layer but PHP is being hit hard, which with wordpress is rather common.

    Agreed, not a node problem, caching will solve most of your issues.

  • AshleyUk said: there is too much of an issue on the node

    AshleyUk said: there is no issues with the Node/VPS

    wot

  • MunMun Member

    Do you have any wordpress caching plugins installed?

  • AshleyUkAshleyUk Member
    edited January 2015

    Typo on the phone, corrected it now :)

    @kcaj said:
    wot

  • Mahfuz_SS_EHLMahfuz_SS_EHL Host Rep, Veteran

    You Should try nGinx other than LSWS, I think you'll se good performance. I have more than 300 concurrent visitor but I see the Load 0.90-1.20 At Most of the time (unless WP Bruteforce is attempted)

  • MunMun Member

    @Mahfuz_SS_EHL said:
    You Should try nGinx other than LSWS, I think you'll se good performance. I have more than 300 concurrent visitor but I see the Load 0.90-1.20 At Most of the time (unless WP Bruteforce is attempted)
    @Mahfuz_SS_EHL said:
    You Should try nGinx other than LSWS, I think you'll se good performance. I have more than 300 concurrent visitor but I see the Load 0.90-1.20 At Most of the time (unless WP Bruteforce is attempted)

    This will most likely due nothing.

    Thanked by 2Dylan cassa
  • Litespeed is, if anything, faster than Nginx.

  • MunMun Member

    @Dylan said:
    Litespeed is, if anything, faster than Nginx.

    Depends on what is being served.

  • Mahfuz_SS_EHLMahfuz_SS_EHL Host Rep, Veteran

    @Mun said:
    Depends on what is being served.

    Yeah, it is. Maybe there's any other problems with the box. He should check deeply.

  • Thanks guys for all the valuable feedback.
    Just so you know, I have been working on optimizing WP but I have a long way to go. All the above details is with site running WP Cache ... (with 24h expiry)

    The site gets random traffic burst and I can expect the load to be high during that. But the server seems to be on avrg giving 3-4 load even when there is nothing much going on.

    And the host has been absolute no help here. Other than suggesting to upgrade and upgrade ... Right now I have moved from 6CPU Core cloud VPS to 14Core CPU cloud VPS and the avg load is still 3 with the same amount of traffic. What does that tell you?? :(

    Going to review my options with setup (ditch cP + LSWS and go with Nginx + Varnish) as well as changing host (14CPU if dedicated should be able to handle 1000+ users without issue with WP Cache enabled but thats not the case here), also looking for alternatives to CloudFlare ... (they have been showing random errors and slowing down site and providing no help at all).
    eg. asking me send tracert after 18 hours of ticket when the issue was already resolved in 2 hours. (I sent them host-tracker.com URL proving it was not an issue at my end at the time but oh well ... they don't really listen)

  • MunMun Member

    nginx + varnish not so great....

    I honestly suggest Apache behind Nginx. Apache is brilliantly fast for PHP and any dynamic pages.

    I'd also take a look at your logs, you may be getting hit by a ton of hotlinking.

  • And check if you have a lot of connections from single or few similar IPs.

    Which LSWS version or license are you using?

  • Well ... Lets see, its not a must to have Nginx + Varnish but it will not hurt to have cache as well along with nginx.

    @DalComp said:
    And check if you have a lot of connections from single or few similar IPs.

    Which LSWS version or license are you using?

    No, don't have connection to a single IP. The site is a news site and gets lots of traffic from FB. (Depending on the news)

    LSWS is 1CPU license .. Latest version.

Sign In or Register to comment.