Port-xen archive

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

Re: SMP and Xen



On Wed, 3 Jan 2007 09:25:43 +1100
"Sarton O'Brien" <bsd-xen%roguewrt.org@localhost> wrote:

> On Wednesday 03 January 2007 02:52, Steven M. Bellovin wrote:
> > I have a dual-processor machine I'm using for Xen.  A few
> > questions...
> >
> > First -- is it safe to use SMP with Xen?  I've heard contradictory
> > opinions on this.  This is Xen3.0.3 on 4.0beta2.
> 
> Although this is Manuel's department, I run current and smp works a
> treat. There are still some parts of acpi dmesg reports as not
> configured but all in all it has been stable and robust.
> 
> Outstanding issues on my end are:
> 
> shutdown -hp does not actually shutdown but -r works fine :)

Occasionally, it's worked for me; more often, it doesn't.  But
'xm destroy' at the right time works...

> Consoling a domu can cause it to spin out of control. Can be very
> frustrating when first implementing a domU. Best advice I can give is
> to enable sshd as fast as humanly possible and save regularly! This
> doesn't happen when under the install kernel thankfully.

I now have a nice dump image -- create/label/newfs a new vnd disk, then
do a restore and edit about two lines in rc.conf... and one line in the
config file...

> 
> > Second -- should my Dom0 see both CPUs?  Currently, it does not.
> 
> Is this nr_cpus when issuing an 'xm info' ?
> 
> xentop should also tell you, as will xm dmesg.
> 
> Apparently under linux, a linux domu may see both cpus but not under 
> netbsd/xen. I haven't played with linux under smp so don't quote me :)

Right.  xentop claims that the Dom0 and the (properly configured) DomU
have 2 vcpus.  However, running 'top' or 'sysctl hw.ncpu' shows only 1.
> 
> > Third -- is there any performance benefit to setting 'vcpus' to 2
> > (for a DomU that would benefit from that)?  That is, will a DomU
> > actually run on more than one CPU?
> 
> My understanding is that it won't run on more than one cpu
> (netbsd/xen). You can force allocation to a particular cpu or allow
> it to dynamically allocate. I've not needed the dedication of a CPU
> but I can see where this may come in handy.

I have no need to force it, but it would be nice if my build machine
were able to use both CPUs simultaneously.
> 
> Hopefully someone else can fill in the gaps if there are any. Hope
> that helps.
> 



                --Steve Bellovin, http://www.cs.columbia.edu/~smb



Home | Main Index | Thread Index | Old Index