WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] simulate slower virtual hosts?

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-users] simulate slower virtual hosts?
From: Mark Williamson <mark.williamson@xxxxxxxxxxxx>
Date: Wed, 10 Jan 2007 03:29:47 +0000
Cc: Frank Doelitzscher <mailing@xxxxxxxxxxxxxxxx>
Delivery-date: Tue, 09 Jan 2007 19:27:10 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200701092218.17890.mailing@xxxxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <200701092218.17890.mailing@xxxxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: KMail/1.9.5
> I experimented with xen a while and for a project I wanted to simulate
> slower maschines than my real host.
>
> I read in the xen manual the command:
>
> xm sched-credit -d <domId> -w <weight>
>
> After failing with that,

What was the failure here?  The credit scheduler is the default in recent Xen 
releases.  Maybe your Xen is older?

You'll probably want to use the -c (cap) switch too, although I'm not *quite* 
sure what it is, so you might want to check its exact semantics match what 
you're trying to do!

> I read a post on this mailing list which gives me 
> the following command:
>
> xm sched-sedf <domId> -e 0 -w <weight>

SEDF is not the default anymore and is, i think, deprecated due to a number of 
issues.  Credit is definitely the preferred option.

I'm surprised this command succeeded if you didn't specifically configure your 
system to use SEDF...  What release of Xen are you running?

> In fact that <weight> must be between 1 and 65535 i multilplied it with 10
> and set:
>
> xm sched-sedf 0 -e 0 -w 10
> xm sched-sedf 0 -e 1 -w 3
>
> I tested the whole thing with an apache benchmark which benchmarked the
> apache running on my virtual host from an extra laptop, but the result was
> negative. The virtual host was as fast as with no weight configured.

I think the -w parameter is supposed to be the ratio period / slice...  Maybe 
trying a fractional value in a range 0 to 1 would work better?  e.g. 0.5 for 
half the CPU time?

Note at this point: be prepared for fiddling with scheduler parameters to lock 
up your system if you make a mistake somewhere.  I'm not sure there's all 
that much sanity checking, so the tools will probably let you set totally 
insane settings.  Just be aware that this might be a consequence of 
misinterpreting the settings and that you may need to do a few resets if this 
happens! ;-)

> I want to know if xen gives me the possibility to run my virtuel hosts with
> less MHz than my real host at all? And when it does, how? Have I made a
> mistake?

You can't run them with less MHz, in that the CPU speed is fixed.  You may be 
able to reduce the proportion of CPU time that is a guest is allowed to 
consume though, which could have a similar (though not identical) effect.

Hopefully we can figure out how to do this for you, although my knowledge of 
the scheduler isn't really very current.

Cheers,
Mark

-- 
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!

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