libvirt/tools
John Ferlan 1f7e811249 virsh: Add iothreadadd and iothreaddel commands
https://bugzilla.redhat.com/show_bug.cgi?id=1161617

Add command to allow adding and removing IOThreads from the domain including
the configuration and live domain.

$ virsh iothreadadd --help
  NAME
    iothreadadd - add an IOThread to the guest domain

  SYNOPSIS
    iothreadadd <domain> <id> [--config] [--live] [--current]

  DESCRIPTION
    Add an IOThread to the guest domain.

  OPTIONS
    [--domain] <string>  domain name, id or uuid
    [--id] <number>  iothread for the new IOThread
    --config         affect next boot
    --live           affect running domain
    --current        affect current domain

$ virsh iothreaddel --help
  NAME
    iothreaddel - delete an IOThread from the guest domain

  SYNOPSIS
    iothreaddel <domain> <id> [--config] [--live] [--current]

  DESCRIPTION
    Delete an IOThread from the guest domain.

  OPTIONS
    [--domain] <string>  domain name, id or uuid
    [--id] <number>  iothread_id for the IOThread to delete
    --config         affect next boot
    --live           affect running domain
    --current        affect current domain

Assuming a running $dom with multiple IOThreads assigned and that
that the $dom has disks assigned to IOThread 1 and IOThread 2:

$ virsh iothreadinfo $dom
 IOThread ID     CPU Affinity
 ---------------------------------------------------
  1               2
  2               3
  3               0-1

$ virsh iothreadadd $dom 1
error: invalid argument: an IOThread is already using iothread_id '1' in iothreadpids

$ virsh iothreadadd $dom 1 --config
error: invalid argument: an IOThread is already using iothread_id '1' in persistent iothreadids

$ virsh iothreadadd $dom 4
$ virsh iothreadinfo $dom
 IOThread ID     CPU Affinity
 ---------------------------------------------------
  1               2
  2               3
  3               0-1
  4               0-3

$ virsh iothreadinfo $dom --config
 IOThread ID     CPU Affinity
 ---------------------------------------------------
  1               2
  2               3
  3               0-1

$ virsh iothreadadd $dom 4 --config
$ virsh iothreadinfo $dom --config
 IOThread ID     CPU Affinity
  ---------------------------------------------------
    1               2
    2               3
    3               0-1
    4               0-3

Assuming the same original configuration

$ virsh iothreaddel $dom 1
error: invalid argument: cannot remove IOThread 1 since it is being used by disk 'vde'

$ virsh iothreaddel $dom 3

$ virsh iothreadinfo $dom
 IOThread ID     CPU Affinity
 ---------------------------------------------------
  1               2
  2               3

$ virsh iothreadinfo $dom --config
 IOThread ID     CPU Affinity
 ---------------------------------------------------
  1               2
  2               3
  3               0-1
2015-04-27 12:36:36 -04:00
..
wireshark Fix common misspellings 2015-03-23 09:01:30 +01:00
libvirt_win_icon_16x16.ico Move virsh into tools/ directory 2009-09-21 14:41:45 +01:00
libvirt_win_icon_32x32.ico Move virsh into tools/ directory 2009-09-21 14:41:45 +01:00
libvirt_win_icon_48x48.ico Move virsh into tools/ directory 2009-09-21 14:41:45 +01:00
libvirt_win_icon_64x64.ico Move virsh into tools/ directory 2009-09-21 14:41:45 +01:00
libvirt-guests.init.in tools: Only install guests init script if --with-init=script=redhat 2012-12-11 19:54:37 -05:00
libvirt-guests.service.in libvirt-guests: run after time-sync.target 2014-09-23 14:35:43 -06:00
libvirt-guests.sh.in libvirt-guests: Allow time sync on guests resume 2015-02-23 08:49:21 +01:00
libvirt-guests.sysconf libvirt-guests: Allow time sync on guests resume 2015-02-23 08:49:21 +01:00
Makefile.am conf: move storage source type to util/ 2014-04-01 10:38:14 -06:00
virsh_win_icon.rc Move virsh into tools/ directory 2009-09-21 14:41:45 +01:00
virsh-console.c Remove unnecessary curly brackets in tools/ 2014-11-14 17:13:36 +01:00
virsh-console.h virsh: Rename vshMakeStdinRaw to vshTTYMakeRaw and move it to virsh.c 2013-09-03 14:06:11 +02:00
virsh-domain-monitor.c virsh: Fix domifaddr output in quiet mode 2015-04-03 12:23:03 +02:00
virsh-domain-monitor.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-domain.c virsh: Add iothreadadd and iothreaddel commands 2015-04-27 12:36:36 -04:00
virsh-domain.h virsh: domain: Split out code to lookup domain from string 2014-08-26 22:48:05 +02:00
virsh-edit.c virsh-edit: Make force editing usable 2015-02-20 07:46:54 +01:00
virsh-host.c Remove unnecessary curly brackets in tools/ 2014-11-14 17:13:36 +01:00
virsh-host.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-interface.c virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh-interface.h Change file names in comments to match the files they are in 2014-03-10 14:26:04 +01:00
virsh-network.c virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh-network.h Change file names in comments to match the files they are in 2014-03-10 14:26:04 +01:00
virsh-nodedev.c Remove unnecessary includes from virsh.h 2015-04-02 10:27:56 +02:00
virsh-nodedev.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-nwfilter.c virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh-nwfilter.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-pool.c Remove unused includes from virsh 2015-04-02 10:27:56 +02:00
virsh-pool.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-secret.c virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh-secret.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-snapshot.c Remove unnecessary includes from virsh.h 2015-04-02 10:27:56 +02:00
virsh-snapshot.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh-volume.c virsh-volume: add support for --reflink 2015-02-03 11:37:30 -05:00
virsh-volume.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virsh.c virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh.h virsh: fix regression in 'virsh event' by domain 2015-04-15 08:13:53 -06:00
virsh.pod virsh: Add iothreadadd and iothreaddel commands 2015-04-27 12:36:36 -04:00
virt-host-validate-common.c maint: avoid static zero init in tools 2014-10-29 09:55:09 -06:00
virt-host-validate-common.h maint: Prohibit "devname" by a syntax check rules 2014-10-01 16:39:01 +02:00
virt-host-validate-lxc.c maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virt-host-validate-lxc.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virt-host-validate-qemu.c maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virt-host-validate-qemu.h maint: fix up copyright notice inconsistencies 2012-09-20 16:30:55 -06:00
virt-host-validate.c Change file names in comments to match the files they are in 2014-03-10 14:26:04 +01:00
virt-login-shell.c Resolve Coverity CHECKED_RETURN 2014-09-15 10:44:27 -04:00
virt-login-shell.conf Introduce a virt-login-shell binary 2013-08-08 16:36:31 +01:00
virt-login-shell.pod virt-login-shell: saner exit value 2014-03-03 12:40:32 -07:00
virt-pki-validate.in virt-pki-validate: add --help/--version option 2013-08-19 20:25:53 -06:00
virt-sanlock-cleanup.in virt-sanlock-cleanup; Fix augtool usage 2013-08-28 13:50:10 +02:00
virt-xml-validate.in tools: add missing 'interface' type and update man page 2013-09-13 14:57:52 +02:00