Results 1 to 11 of 11
  1. #1
    Join Date
    Nov 2002
    Posts
    85

    My VPS Feels slow

    I've got a VPS that I don't currently use for anything.

    Every time I jump on and have a think about doing anything it just feels slow. Plenty of free memory and CPU, when I mean not used I really mean it :-)

    I've attached a "vmstat 1" from earlier when I installed 4 packages through yum.

    It took 2 or 3 minutes just to read through the package list and then another 4 minutes to install the packages. Host is running openvz+hypervm from what I know.

    I'm looking for pointers on where I might look to confirm if it is an IO issue or something on the host box I'm on.

    Cheers,

    J

  2. #2
    Those I/O numbers are very low, when writing a big blank file I see 102544, but this isn't necessarily the problem. It could be that reading through the package list doesn't require that much disc activity.

    To get a better understanding you might try these simple tests. To measure CPU speed run
    Code:
    openssl speed bf
    For comparison my 1200MHz laptop gets about 44000, and my desktop close to 100000. This test measures CPU time so isn't affected by system load, which is of course important so also try
    Code:
    openssl speed bf -elapsed
    If the CPU looks fine then try some pure disc I/O
    Code:
    sync ; time (dd if=/dev/zero of=testdiscperf.tmp bs=10M count=10 ; sync)
    It will create a 100MB file and send it to disc. Ignore dd's reported speed as it is the sync afterwards that takes the time sending data to disc. A simple division by the real time taken and you have a very rough measurement of I/O speeds. If you had a disc all to yourself you might expect around 40MB/s.

    Hope that helps a little,

    Jim
    Blue Room Hosting - High availability UK VPS
    KVM Plans - Multiple OS support. Virtual console and CD drive.

  3. #3
    Join Date
    Nov 2002
    Posts
    85
    Thanks for the ideas Jim.

    openssl speed bf

    The 'numbers' are in 1000s of bytes per second processed.
    type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes
    blowfish cbc 86500.40k 87573.68k 89787.65k 93182.07k 93558.82

    openssl speed bf -elapsed

    The 'numbers' are in 1000s of bytes per second processed.
    type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes
    blowfish cbc 30927.00k 30707.89k 30544.67k 31774.35k 32350.95k
    Both of those look fairly decent, ok onto the next one.

    sync ; time (dd if=/dev/zero of=testdiscperf.tmp bs=10M count=10 ; sync)

    /dev/zero didn't exist, created it using:

    mknod /dev/zero c 1 5
    Anyway, results of your suggestion are:

    104857600 bytes (105 MB) copied, 0.457382 seconds, 229 MB/s

    real 0m40.436s
    user 0m0.000s
    sys 0m0.295s
    Sloooow

  4. #4
    Join Date
    Aug 2006
    Location
    Ashburn VA, San Diego CA
    Posts
    4,615
    Doesn't seem slow to me. Are you sure you don't have a network issue? Perhaps the Yum mirror you're using is too far away or overloaded?

    What are the results of some traceroutes to popular sites?

    Network download speed tests?
    Fast Serv Networks, LLC | AS29889 | DDOS Protected | Managed Cloud, Streaming, Dedicated Servers, Colo by-the-U
    Since 2003 - Ashburn VA + San Diego CA Datacenters

  5. #5
    Ouch, 40 seconds to write 100MB is rather painful. I know this is a terrible test really, you have no way of knowing how much other activity is also sent to disc on the second sync, but even so what you see is what you get. It still takes 40 seconds to write *your* 100MB to disc.

    I think this all adds up. If it is an OpenVZ system then it may well be that it is heavily oversubscribed. If the provider is selling more memory than they have then the system will start swapping a lot, hence the poor disc I/O. It doesn't have to be this way, many providers do not oversubscribe so you might want to move if you ever get around to using your VPS.

    Jim
    Blue Room Hosting - High availability UK VPS
    KVM Plans - Multiple OS support. Virtual console and CD drive.

  6. #6
    Join Date
    Nov 2002
    Posts
    85
    Quote Originally Posted by blueroomhosting View Post
    Ouch, 40 seconds to write 100MB is rather painful. I know this is a terrible test really, you have no way of knowing how much other activity is also sent to disc on the second sync, but even so what you see is what you get. It still takes 40 seconds to write *your* 100MB to disc.
    Jim
    No worries, I think I'll ask to be moved to another node, see if that brings any improvement.

    Cos it's still sloooow.

    104857600 bytes (105 MB) copied, 0.516435 seconds, 203 MB/s

    real 1m1.750s
    user 0m0.002s
    sys 0m0.364s

  7. #7
    Join Date
    Feb 2004
    Posts
    371
    Seems like a swapping node to me (according to writing test).

    Thank XenSource for Xen.

    My personal VPS a full node but on SATA RAID-10 (Xen) I'm getting this
    # sync ; time (dd if=/dev/zero of=testdiscperf.tmp bs=10M count=10 ; sync)
    10+0 records in
    10+0 records out
    104857600 bytes (105 MB) copied, 0.325041 seconds, 323 MB/s

    real 0m0.786s
    user 0m0.000s
    sys 0m0.304s
    Last edited by ctaborda; 05-11-2008 at 11:22 PM.

  8. #8
    Join Date
    Nov 2002
    Posts
    85
    Nice speeds, I checked against another two XEN VPSs that I have and both take between 4 and 5 seconds for the write, which is close to 20MB/sec, way better than my slow box

  9. #9
    Join Date
    Nov 2002
    Posts
    85
    Just to update, I was moved to a new node.

    Results are much faster now, under 3 seconds to write 100mb to disk as opposed to over a minute in some cases previously.

    sync ; time (dd if=/dev/zero of=testdiscperf.tmp bs=10M count=10 ; sync)
    10+0 records in
    10+0 records out
    104857600 bytes (105 MB) copied, 0.201 seconds, 522 MB/s

    real 0m2.704s
    user 0m0.000s
    sys 0m0.237s
    Feels much more responsive now when doing disk intensive tasks.
    Last edited by geekboy; 05-13-2008 at 07:43 PM. Reason: Selling

  10. #10
    Join Date
    Feb 2004
    Posts
    371
    Great news!!!

    See, it was an oversold machine. Meaning, they were giving more ram than they had, and it was swapping.

    Hey great so see they did the right thing for you!

    Best of luck!

  11. #11
    Join Date
    Sep 2005
    Location
    Canada
    Posts
    646
    Quote Originally Posted by blueroomhosting View Post
    Ouch, 40 seconds to write 100MB is rather painful. I know this is a terrible test really, you have no way of knowing how much other activity is also sent to disc on the second sync, but even so what you see is what you get. It still takes 40 seconds to write *your* 100MB to disc.
    Its that disparity between the write time and 'real' time thats killing that server. Its buffering in memory heavily to compensate for a very busy disk.
    Last edited by vpsville; 05-14-2008 at 09:30 AM.
    VPSVille.com
    Toronto, London, Dallas, Los Angeles
    Quality VPS hosting on Premium bandwidth

Posting Permissions

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