[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-devel] [RFC] [PATCH] Accurate accounting for credit scheduler


  • To: xen-devel@xxxxxxxxxxxxxxxxxxx, Keir Fraser <keir.fraser@xxxxxxxxxxxxx>, Steven Hand <Steven.Hand@xxxxxxxxxxxxx>
  • From: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
  • Date: Tue, 25 Aug 2009 15:23:07 +0100
  • Cc:
  • Delivery-date: Tue, 25 Aug 2009 07:23:35 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=ewf2NKtW/g8FnVU6ILBuynVyQxnlNxkAC6fwgYtW8d+mmAvY3ImANWq7zWLVm4DSJC WQPIQaU+87TOP6WdFtx6umgwNrCnnnR1xaIF2E6stk+KEJ30bJ1rRUch2avkoR2P2igZ 6/ctM03sjqRCEWzj2XCBe7pbcZ4loyd+rmofg=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

The attached patch implements a first-cut of accurate TSC-based
accounting for the Credit scheduler.  Rather than debit a full 10ms of
credit on a scheduler tick (probabilistic), it debits credits
accurately based on time stamps.

The main problem this is meant to address is an attack on the
scheduler that allows a rogue guest to avoid ever being debited
credits.  The basic idea is that the rogue process checks time (using
rdtsc) periodically, and yields after 9.5ms.  Using this technique, a
guest can "steal" 95% of the cpu.  This is particularly an issue in
cloud environments.

Whenever we get a final version of this patch, it should be backported
to earlier versions as well.

Signed-off-by: George Dunlap <george.dunlap@xxxxxxxxxxxxx>

 -George

Attachment: accurate-credit.patch
Description: Text Data

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.