Howdy, Stranger!

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


VPS CPU limits (vps gets shutdown by host).
New on LowEndTalk? Please Register and read our Community Rules.

VPS CPU limits (vps gets shutdown by host).

Hi guys,

I recently moved to an OpenVZ host listed on LowEndBox, moving a vps which we had running on a similarly spec Xen host for the last year with no problems at all. Both vps's are advertised as 512mb/1v-cpu. The reason we moved to the new host was for extra bandwidth.

The vps is used to run php/mysql based script which runs once a day and:

  • reads our supplier websites for data (~2gb bandwidth)
  • sorts the data into categories
  • ftps the zipped up data to our live server.

Which takes anywhere from 3 - 5 hours to run. This was all set up fine, but after running for 1 week on our new host, we were shut down for excessive cpu use. Quoting the host:

"Keep in mind that you were using 10 E3-1240v2 cores with your VPS by itself."

Can anyone shed some light on how/why this is happening? I think it is because we switched to a OpenVZ container, which does not have the same resource limiting functionality. I admit our script does use a lot of CPU/Memory (1 mill records are being sorted), but if it takes 5 minutes or 5 hours, it doesn't matter, it just needs to happen once a day, as it was on our old host. My understanding is it shouldn't matter to our host what cpu/mem scripts we are running, as they should be limited to our VPS container.

Comments

  • RadiRadi Member, Provider

    Who is the OVZ host?

    4 GB RAM/90 GB SSD/4 TB Traffic/KVM/1 IPv4 for $7/mo only here with coupon code "LET-It-GO".

  • budi1413budi1413 Member
    edited November 2013

    Wait, what? E3 have 10 cores? What the maximum load you produce during the process?

  • maybe you can use cpulimit to limit cpu usage by yourself?

  • matt_securedspeedmatt_securedspeed Member, Provider

    He probably meant your CPU load was 10. Is it possible that your last provider just ignored/didn't care about your high CPU use?

    SecuredSpeed - Fast, Affordable, & Reliable VPS Solutions. Gigabit uplinks, SSD's, native IPv4/IPv6, & instant setup.
  • From my experience xen have better cpu isolation.

  • perennateperennate Member, Provider

    My understanding is it shouldn't matter to our host what cpu/mem scripts we are running, as they should be limited to our VPS container.

    It does, since the VPS shares a core and won't be automatically rate limited if the system detects that it is using more than it's fair share for a long duration. What do you mean "shut down"? Did they just reboot your VM or also delete your data?

    Also a few hours every day not a short duration.

  • It is possible because your last host was using Xen you were only provided access to 1-2 cores or limited to 1 dedicated core which prevented your load from effecting the node as much overall. Have you noticed your script finishing more quickly than it was on the other host? I would hope if your using 10x the cpu time it is at least completing that much faster? If you provider can't limit you to less cores, you may consider using cpulimit like @JerryHou suggested. You can then set it to use less of the CPU and would hopefully prevent the abuse situation.

    Cheers!

    Have an Allwinner H3 device? Check out H3Droid! | Lichee Pi Zero - The 6$ SBC | #SYSarm - Get It! | Armbian | Atomic Pi Mirror
    22+ Years IT Experience in Linux/Windows Hosting, Administration and Development Services

  • @snowblind data parsing like that takes a lot of resources. If I may suggest, get a cheap dedibox. :)

    Happy to be alive and kicking!

  • If time is not an issue, can go with the vps solution but lower the cpu usage by limiting it or asking the host to do it (alternatively, give only one core, but that will lock it solid for the duration).

    Extremist conservative user, I wish to preserve human and civil rights, free speech, freedom of the press and worship, rule of law, democracy, peace and prosperity, social mobility, etc. Now you can draw your guns.

  • said: it takes 5 minutes or 5 hours, it doesn't matter

    Maybe you can try to use the "nice" command to schedule your script with the lowest priority.

  • nice will probably not work as it will still hog all available cycles and depending on the number of allocated cores and content switching will still wreck havoc.
    Should be throttled some other way, but indeed, Xen has a much better scheduler.

    Extremist conservative user, I wish to preserve human and civil rights, free speech, freedom of the press and worship, rule of law, democracy, peace and prosperity, social mobility, etc. Now you can draw your guns.

  • @snowblind is the data in form of delimited text or it is curled directly from life page? If it is delimited, you can make a script to slice the data into smaller chunks and use cron to process it in sequence, so bursting should not take longer than 60 seconds with a 3-5 minutes interval to process each chunk.

    Happy to be alive and kicking!

  • i think the main problem wasnt what virtualization do you use but who is your host.
    there are some good OVZ provider like futurehosting and knownhost, BUT, if your vps has server load 10. I doubt any provider want to host your vps.
    bytheway, did your first host use ssd or ssd cache? i just think the problem is on disk i/o that made high cpu load

    Tuguhost March Deal -
    1 GB Ram Linux Vps = $25/year !

  • drserverdrserver Member, Host Rep
    edited November 2013

    @snowblind
    If you are using lot of cpu, please look at our new XEN offer with dedicated H/T core

    http://lowendtalk.com/discussion/16908/drserver-xen-hvm-1gb-ram-dedicated-h-t-core-30gb-drive-1tb-1gbps-6-5-usd-m

    Unmetered servers starting from $12.00 USD p/m. Xeon® E-2134 for $50.00 p/m ||| Xeon® Silver 4110 for $80.00 p/m
    Live server stock ||| Feel free to contact me for custom deal.

  • I would suggest that you simply go back to your old host and pay for some extra bandwidth. Xen cpu isolation and scheduler is its best feature imo. Most hosts will not allow you to run a high load for hours and rightly so if it impacts other people.

    Thanked by 1Maounique

    I am no longer active here, find me at https://talk.lowendspirit.com

  • I had the same issue with LEB providers previously. After migrated to Linode, no more such warning.

Sign In or Register to comment.