[libvirt] [PATCH v4 4/9] virsh: Add 'iothreadsinfo' command

Daniel P. Berrange berrange at redhat.com
Fri Mar 6 09:55:40 UTC 2015


On Thu, Mar 05, 2015 at 09:03:01PM -0500, John Ferlan wrote:
> Add the 'iothreadsinfo' command to display IOThread Info data. Allow for
> [--live] or [--config] options in order to display live or config data
> for an active domain.
> 
> $ virsh iothreadsinfo --help
>   NAME
>     iothreadsinfo - view domain IOThreads
> 
>   SYNOPSIS
>     iothreadsinfo <domain> [--config] [--live] [--current]
> 
>   DESCRIPTION
>     Returns basic information about the domain IOThreads.
> 
>   OPTIONS
>     [--domain] <string>  domain name, id or uuid
>     --config         affect next boot
>     --live           affect running domain
>     --current        affect current domain
> 
> An active domain may return:
> 
> $ virsh iothreads $dom
>  IOThread ID     CPU Affinity
> ---------------------------------------------------
>   1               2
>   2               3
>   3               0
> 
> $ echo $?
> 0
> 
> For domains which don't have IOThreads the following is returned:
> 
> $ virsh iothreads $dom
> No IOThreads found for the domain
> 
> $ echo $?
> 0
> 
> For domains which are not running the following is returned:
> 
> $ virsh iothreads $dom --live
> error: Unable to get domain IOThreads information
> error: Requested operation is not valid: domain is not running
> 
> $ echo $?
> 1
> 
> Editing a domains configuration and modifying the iothreadpin data for
> thread 3 from nothing provided to setting a cpuset of '0-1' and then
> displaying using --config would display:
> 
> $ virsh iothreads f18iothr --config
>  IOThread ID     CPU Affinity
>  ----------------------------
>   1               2
>   2               3
>   3               0-1
> 
> $
> 
> Signed-off-by: John Ferlan <jferlan at redhat.com>
> ---
>  tools/virsh-domain.c | 94 ++++++++++++++++++++++++++++++++++++++++++++++++++++
>  tools/virsh.pod      | 12 +++++++
>  2 files changed, 106 insertions(+)

ACK


Regards,
Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|




More information about the libvir-list mailing list