Bug 1020899 - libvirt should throw error when tried to add the cpus if it has been already added
Summary: libvirt should throw error when tried to add the cpus if it has been already ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Libvirt Maintainers
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-18 13:28 UTC by chandrashekar shastri
Modified: 2013-10-18 13:38 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-18 13:38:43 UTC


Attachments (Terms of Use)

Description chandrashekar shastri 2013-10-18 13:28:35 UTC
If the guest is already assigned with maxmimum cpus then if the user tries to assign to assign the same cpu then the libvirt should be handle it in a better way.

[root@phx2 qemu]# virsh vcpucount RHEL_WORKING 
maximum      config        20
maximum      live          20
current      config         9
current      live          20

[root@phx2 qemu]# virsh setvcpus RHEL_WORKING 20

[root@phx2 qemu]# echo $?
0
[root@phx2 qemu]# virsh vcpucount RHEL_WORKING 
maximum      config        20
maximum      live          20
current      config         9
current      live          20

[root@phx2 qemu]# virsh setvcpus RHEL_WORKING 20 --live 

[root@phx2 qemu]# echo $?
0
[root@phx2 qemu]#

Comment 1 chandrashekar shastri 2013-10-18 13:30:04 UTC
It should throw error or message saying that the guest is allocated with maximum number of cpus.

Comment 2 Peter Krempa 2013-10-18 13:38:43 UTC
The function sets the CPU count to the amount requested by the user. If the requested value is same as the previously used value, the semantics of the "set" operation are to keep the value and return success.

As this behaves as it was originally intended, I'm closing this as NOTABUG.


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