The ovm_vmcontrol script lets you configure CPU pinning, which is also referred to as hard partitioning, on virtual machines.
The ovm_vmcontrol script supports CPU pinning for virtual machines running on x86-based Oracle VM Servers only. You cannot configure CPU pinning for virtual machines running on Oracle VM Server for SPARC.
If you are using Oracle VM Release 3.4.1 or Release 3.4.2, after you configure CPU pinning for a virtual machine, you must stop and then start the virtual machine for the configuration to take effect. Restarting the virtual machine does not load the configuration changes for CPU pinning.
As of Oracle VM Release 3.4.3, support for dynamic CPU pinning is available. As a result, after you configure CPU pinning for a virtual machine, there is no longer a requirement to stop and then start the virtual machine for the configuration to take effect.
Syntax
ovm_vmcontrol
{
-u
} [
username
-p
|
password
-E
] {
-h
} {
hostname
-c
} {
command
-v
|
vm_name
-U
} [
vm_uuid
-s
...
]cpu_thread_list
Where
is:
command
{
setvcpu
|
getvcpu
|
rmvcpu
}
Options
The following table shows the available options for this command.
Option | Description |
---|---|
| Username of an Oracle VM Manager admin user. This option is required. |
[
| Corresponding password for the Oracle VM Manager admin user. You can specify the password as follows:
|
{
| Hostname of the server running Oracle VM Manager. |
| Command to execute. This option is required.
The |
| Virtual machine name. |
|
Virtual machine UUID. If you do not specify the virtual
machine name with the |
| List of physical thread numbers to which you can bind virtual CPUs. You can set the value as follows:
Note
You must not set a number as the value for the
You must use this command in combination with:
|
Examples
Example 9.1 Setting CPU pinning for a virtual machine
This example binds the virtual CPUs of the virtual machine to threads 0, 1, 3, 5, and 7.
# ./ovm_vmcontrol -u admin -h localhost -v MyVM01 -c setvcpu -s 0-3,^2,5-7,^6
Oracle VM VM Control utility 2.1.
Connecting to OVM Manager using Web Service.
Connected.
OVM Manager version: version
Command : setvcpu
Pinning vCPU '0-3,^2,5-7,^6' to VM 'MyVM01'
Pin vCPU succeed.
Example 9.2 Checking CPU pinning for a virtual machine
This example shows the virtual CPUs of the virtual machine are bound to threads 0, 1, 3, 5, and 7.
# ./ovm_vmcontrol -u admin -h localhost -v MyVM01 -c getvcpu
Oracle VM VM Control utility 2.1.
Connecting to OVM Manager using Web Service.
Connected.
OVM Manager version: version
Command : getvcpu
Getting pinned CPU list...
Current pinned CPU:0-3,^2,5-7,^6