Bug 1232663 - cannot change the nodeset if we do not set the numatune in guest xml
Summary: cannot change the nodeset if we do not set the numatune in guest xml
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt
Version: 7.2
Hardware: x86_64
OS: Linux
Target Milestone: rc
: ---
Assignee: Michal Privoznik
QA Contact: Virtualization Bugs
Depends On:
TreeView+ depends on / blocked
Reported: 2015-06-17 09:14 UTC by Luyao Huang
Modified: 2015-11-19 06:41 UTC (History)
5 users (show)

Fixed In Version: libvirt-1.2.17-3.el7
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2015-11-19 06:41:31 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2202 0 normal SHIPPED_LIVE libvirt bug fix and enhancement update 2015-11-19 08:17:58 UTC

Description Luyao Huang 2015-06-17 09:14:29 UTC
description of problem:
cannot change the nodeset if we do not set the numatune in guest xml

Version-Release number of selected component (if applicable):


How reproducible:

Steps to Reproduce:

1. prepare a guest *without* numatune settings:

  <memory unit='KiB'>1024000</memory>
  <currentMemory unit='KiB'>1024000</currentMemory>
  <vcpu placement='static'>5</vcpu>
    <type arch='x86_64' machine='pc-i440fx-rhel7.2.0'>hvm</type>
    <boot dev='hd'/>

2. start it and check the numa policy:
# virsh start test4
Domain test4 started

# virsh numatune test4
numa_mode      : strict
numa_nodeset   :


# virsh numatune test4 --mode strict --nodeset 1
error: Unable to change numa parameters
error: Requested operation is not valid: change of nodeset for running domain requires strict numa mode

Actual results:
Cannot change the nodeset if we do not set the numatune in guest xml

from 2 step we know the mode is strict, but when we change the nodeset, libvirt
point out that our mode is not strict

cannot reproduce this issue with libvirt-1.2.15-2.el7.x86_64, so i think maybe this is a regression

Expected results:
2 option

1. show the "default" when we use numatune to check the mode, because we didn't set the numa bind mode in guest xml, and the display from numatune is against itself when we change the node set.

2. allow change the nodeset in step 3 (if with cgroup), because we allow change the nodeset even the guest have no numatune settings in libvirt-1.2.15-2.el7.x86_64, and as we change the nodeset via cgroup, we do not use the libnuma API if cgroup is available.

Comment 1 Michal Privoznik 2015-07-13 16:30:47 UTC
Patch proposed upstream:


Comment 4 hongming 2015-08-27 09:46:19 UTC
Verify it as follows. The result is expected. Move its status to VERIFIED.

# rpm -q libvirt

# virsh start test4
Domain test4 started

# virsh dumpxml test4|grep numatune

# virsh numatune test4
numa_mode      : strict
numa_nodeset   : 

# virsh numatune test4 --mode strict --nodeset 1

# virsh numatune test4
numa_mode      : strict
numa_nodeset   : 1

# virsh dumpxml test4|grep /numatune -B2
    <memory mode='strict' nodeset='1'/>

# virsh list
 Id    Name                           State
 21    test4                          running

# numastat -p `pidof qemu-kvm`

Per-node process memory usage (in MBs) for PID 27929 (qemu-kvm)
                           Node 0          Node 1           Total
                  --------------- --------------- ---------------
Huge                         0.00            0.00            0.00
Heap                         0.00            6.87            6.87
Stack                        0.00            2.09            2.09
Private                      0.02         2033.41         2033.43
----------------  --------------- --------------- ---------------
Total                        0.02         2042.37         2042.39

Comment 6 errata-xmlrpc 2015-11-19 06:41:31 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.