Académique Documents
Professionnel Documents
Culture Documents
sales@mokumsolutions.com
Copyright 2014 Mokum Solutions, Inc. All rights reserved.
Distribution of the Oracle Cloud Cookbook or derivative of the work in any form
is prohibited unless prior permission is obtained from the Copyright holder.
About Mokum Solutions, Inc.
Founded in March 2011, Mokum Solutions, Inc. specializes in the implementation,
delivery and support of Oracle technologies in private and public clouds. Mokum
corporate headquarters are located in San Francisco, CA http://mokumsolutions.com
or call 1 415 252 9164
About the Author
The author of the Oracle Cloud Cookbook is none other than the owner of
Mokum Solutions, Inc., Roddy Rodstein. Roddy is one of the most respected
Oracle Cloud Computing experts, having designed and managed many of the
worlds largest and most complex Oracle private clouds. Before establishing
Mokum in March 2011, Roddy spent three years at Oracle on the Oracle VM
and Oracle Linux team designing and supporting Oracle's largest and most
complex customer environments. Before Oracle, Roddy spent six years at Citrix,
designing and supporting Citrix's largest and most complex customer environments,
Including Oracle's. With Mr. Rodsteins rich background and knowledge, there
can be no better resource for revealing the Oracle Cloud recipe.
Audience
The Oracle Cloud Cookbook is a comprehensive, field tested reference design that
guides you through each step to move to your Oracle software portfolio to an elastic
Oracle cloud using the Oracle VM product line, Oracle Linux, Oracle Engineered
Systems managed by Oracle Enterprise Manager 12c, with total control over Oracle
processor licensing.
http://mokumsolutions.com
Table of Contents
Oracle Licensing and Hard and Soft Partitioning with Oracle VM
Hard Partitioning RAC and RAC One Node with Oracle VM
Change Description
Updated By
Date
1.0
Document Creation
Roddy Rodstein
07/11/12
1.0
Content Refresh
Roddy Rodstein
06/16/14
4 of 27
http://mokumsolutions.com
server virtualization, Oracle processor licensing is dynamic, with each Oracle product
allocated to a subset of a hypervisor's CPUs, this is referred to as hard partitioning,
and/or bound to a single hypervisor, or a subset of hypervisors within a cluster, this is
referred to as soft partitioning. Unlike hard partitioning that allows us to license
a subset of a hypervisor's CPUs to Oracle products, soft partitioning requires all of
a hypervisor's processors to be licensed for each Oracle product. Many Oracle
customers often select standard editions products over enterprise editions products to
reduce Oracle licensing costs. The Oracle Software Investment Guide (SIG) states that
Oracle standard edition products are limited to 4 CPU sockets. Oracle standard edition
products are fully supported with Oracle VM soft partitioning. Understanding how to
use hard and soft partitioning with Oracle VM can help your organization gain total
control of their Oracle licensing costs.
Since the rst release of Oracle VM, which was announced at Oracle Open World in
November 2007, Oracle has provided certied support for Oracle technology products
on Oracle VM, including both hard and soft partitioning for Oracle licence management.
Oracle VM is Oracle's agship server virtualization solution that makes Oracle
applications easier to deploy, manage, support, and license. Oracle VM is the only x86
virtualization solution that Oracle tests, certies and is fully supported by Oracle for
Oracle technology products. Oracle does not test, certify, or support Oracle technology
products on any Non-Oracle x86 virtualization solutions. With Non-Oracle x86
virtualization solutions, the only Oracle licensing option is soft partitioning.
To help understand how to use Oracle VM as an Oracle license management tool, lets
review how Oracle processor licensing is calculated. Oracle processor licensing is
calculated by counting the number of each CPU core accessed by an operating system
running an Oracle technology product, this calculation is called a processor factor.
Oracle recognizes each CPU core as a separate CPU and each CPU type with a dierent
processor factor.
Table 1 lists Oracle' processor factors.
Oracle Processor
Licensing
Processor
Factor
UltraSparc T1
0.25
AMD/Intel
0.50
0.75
1.00
5 of 27
http://mokumsolutions.com
List 1 shows the processor factor for a single socket four, eight, ten, twelve and sixteen
core Intel and/or AMD CPU.
Intel or AMD CPU
1 four core CPU requires 2 processor licenses
1 eight core CPU requires 4 processor licenses
1 ten core CPU requires 5 processor licenses
1 twelve core CPU requires 6 processor licenses
1 sixteen core CPU requires 8 processor licenses
As shown in List 1, as the core count increases, so does the Oracle processor license
count.
Intel/AMD CPUs have Hyperthreading technology that makes one CPU core look like
two. From an Oracle processor licensing perspective, Hyper-threading does
not increase the Oracle processor license count. Enabling Hyper-threading will
increase the overall processor capacity of an Oracle VM Server, and an Oracle VM
Server pool. For example, with hyper-threading disabled, a CPU is running a single
thread per core. With hyper-threading enabled, the number of threads within a core
double, and virtual machines can use the additional threads without incurring
additional Oracle processor licensing penalties. With hyper-threading enabled, a virtual
machine with 4 CPUs is actually is accessing 2 CPU cores, 4 CPU threads, or 1 Oracle
CPU license. With hyper-threading disabled, the same virtual machine with 4 CPUs is
actually is consuming 4 CPU cores, or 2 Oracle CPU license. Oracle recognizes each
CPU core as a separate CPU and each CPU type with a dierent processor factor. The
processor factor determines the processor count. The processor count determines the
number of processors required to license the Oracle product.
With Oracle VM, hard partitioning allows us to pin a virtual machine's CPUs to a subset
of an Oracle VM Servers CPU cores, and only pay Oracle for the pinned CPUs. For
example, with Oracle VM hard partitioning, a standard or enterprise edition Database
could run on a virtual machine that is pinned to an Oracle VM Server with 4 CPUs (four
sockets) each with 24 cores (96 cores), and you only pay Oracle for the pinned CPUs,
i.e. you can pin the virtual machine's CPUs to the exact number of CPUs you need. The
same virtual machine running on a VMWare server with 4 CPUs (four sockets) each
with 24 cores (96 cores) with a standard or enterprise edition Database would require
48 Oracle processor licenses. With any Non-Oracle x86 virtualization solutions, the only
Oracle licensing option is soft partitioning. With hard partitioning you only pay Oracle
for the CPUs you actaully need/pin.
Soft partitioning requires all of the physical server's processors to be licensed. The
number one use case with soft partitioning is the ability to license a subset of Oracle
VM Servers within a cluster. For example, with Oracle VM soft partitioning, a standard
or enterprise edition Database could run on virtual machines that are restricted to
a subset of Oracle VM Servers within a cluster, for example 2 Oracle VM Servers from
32, essentally reducing the processor count and licensing costs from 32 servers to 2
servers. Customers elect to use soft parttitoning over hard partitiong to take advantage
of Oracle VM's Live Migration, Distributed Resource Scheduler (DRS) and Distributed
Power Management (DPM) features that are only supported with soft partitioning. The
6 of 27
http://mokumsolutions.com
use of hard and soft partition will inuence your Oracle VM server pool design.
Tip: Hard and soft partitioned virtual machines can be restricted to one or more Oracle
VM Servers by placing the virtual machine les on a storage repository that is
presented only to the Oracle VM Server(s) were the virtual machine can run.
Table 1 provides an overview of hard and soft partitioning with Oracle VM.
Partitioning
Overview
Type
Requirements
Hard
Partitioning
Soft
Partitioning
The next example in Figure 1 shows three AMD/Intel servers, each server has two eight
core CPUs with a processor factor of eight. The rst AMD/Intel server is an example of
a physical server with an operating system installed directly on the server hardware,
running a single Oracle 11G Database. The second AMD/Intel server is an example of
soft partitioning with Oracle VM installed directly on the server hardware running eight
virtual machines, each virtual machine is running an Oracle 11G Database. The third
AMD/Intel server is an example of hard partitioning with an Oracle VM installed
directly on the server hardware running eight virtual machines, and only one of the
eight virtual machines is running an Oracle 11G Database with one pinned Oracle
processor license.
7 of 27
http://mokumsolutions.com
As shown in Figure 1, the rst AMD/Intel physical server has only one Oracle 11G
Database licensed with soft partitioning with eight Oracle processor licenses. With
physical servers, Oracle processor licensing is xed, with each Oracle product bound to
a physical server licensed by the number of the server's processors. Regardless of the
number of Oracle processor licenses you need, you must pay Oracle for all of the
physical server's processors. The second AMD/Intel Oracle VM example is licensed with
soft partitioning running eight Oracle 11G Database virtual machines, with eight Oracle
processor licenses. In contrast to the rst example with an operating system installed
directly on the server hardware running a single Oracle 11G Database, the second
example shows how Oracle VM with soft partitioning can run 8 or more Oracle 11G
Database virtual machines on the same hardware as the physical server with 1 Oracle
Database. An Oracle VM Server's CPU, RAM and I/O resources determine the number of
virtual machines that can simultaneously run. I select the number 8 as an arbitrary
example. The third AMD/Intel Oracle VM example is licensed with hard partitioning
one Oracle 11G Database virtual machine using as little as one up to eight Oracle
processor license. Using hard partitioning you can license only the CPU you need
regardless of the physical server's processor factor. The additional Oracle VM Server
CPUs could be used to hard partition other Oracle technologies, or be used to run other
workloads along side the hard partitioned Oracle 11G Database virtual machine.
Tip: We can restrict hard partitioned virtual machines to one or more Oracle VM
Servers by placing the virtual machine les on a storage repository that is presented
only to the Oracle VM Server(s) where the virtual machine can run.
The next hard partitioning example in Figure 2 shows an Oracle VM Server with two
eight core Intel CPUs, with one hard partitioned virtual machine running an Oracle 11G
Database. The virtual machine is pinned to two of the Oracle VM Servers CPU cores (2
cores = 1 CPU license). From an Oracle licensing perspective, the Oracle VM Server
has a processor factor of 8. Using hard partitioning, the pinned virtual machine
requires only 1 Oracle processor license. The additional 7 CPUs could be used to hard
8 of 27
http://mokumsolutions.com
partition other Oracle technologies or be used to run other workloads on the same
Oracle VM Server.
The next hard partitioning example in Figure 3 shows an Oracle VM Server with two
eight core Intel CPUs, with two pinned virtual machines running an Oracle 11G
Database. The virtual machines are pinned to the same CPU cores, with a processor
factor of 1. Its possible to pin multiple virtual machines running an Oracle 11g
Database to the same CPU cores, and only pay for the pinned CPU cores. In this
example multiple virtual machines are running Oracle 11g Databases using the same
CPU cores, and the same license. Please note that since each virtual machine is pinned
to the same CPU cores, the performance of each virtual machine may be impacted by
CPU contention. The additional 7 CPU cores could be used to hard partition other
Oracle technologies or be shared for other workloads on the Oracle VM Server.
9 of 27
http://mokumsolutions.com
Soft
10 of 27
http://mokumsolutions.com
Figure 5 shows the same Oracle VM server pool as in Figure 4, with a total of 96 cores
and a processor factor of 48 Oracle CPU licenses. In Figure 5, there are a total of 8
virtual machines in the pool running Oracle Database 11G that are pinned to two of the
six Oracle VM Servers. The soft partitioning scenario shown in Figure 5 requires only
16 Oracle CPU licenses.
The example shown in Figure 5 supports Live Migration without Distributed Resource
Scheduler (DRS) and/or Distributed Power Management.
11 of 27
http://mokumsolutions.com
Oracle VM
Oracle has a wide variety of high availability solutions for databases, applications and
virtualization that oer dierent levels of availability. Hard and soft partitioning with
Oracle VM can be used with Oracle RAC, RAC One Node, DataGuard and Application
Server Guard to provide an additional layer of high availability with total control over
Oracle CPU licensing costs.
Oracle VM's high availability features are complementary with Oracle's high availability
solutions for databases, Fusion Middleware and applications. For example, Oracle VM
high availability (HA) detects and responds to catastrophic Oracle VM Server failures
by restarting virtual machines, RAC nodes, RAC One Nodes, DataGuard and/or
Application Server Guard nodes on a live Oracle VM Server. Oracle VM Live Migration
is used to eliminate planned downtime by migrating running virtual machines from one
Oracle VM Server to another Oracle VM Server during a maintenance event, i.e. for
repairs or an upgrade. Hard and soft partitioning with Oracle VM can be used with
RAC, RAC One Node, DataGuard and Application Server Guard to provide and
additional layer of high availability with total control over Oracle CPU licensing costs.
RAC is one of Oracles database high availability solutions that oers operational
continuity in the event of server and hardware failure. If one RAC node in a multi node
RAC cluster fails, the Oracle database would continue to run without disruption of
service. An Oracle 11g Database R2 feature named RAC One Node, also oers database
high availability in the event of catastrophic failure, with a single node architecture.
Both RAC and RAC One Node are certied and supported with Oracle VM. Hard
partitioning with Oracle VM can be used with RAC and RAC One Node to provide
database high availability with total control over Oracle CPU licensing costs.
Figure 6 shows how hard partitioning with Oracle VM can be used with RAC to gain
total control over processor licensing costs.
12 of 27
http://mokumsolutions.com
If reducing costs, Database high availability and Live migration is a requirement, RAC
One node with Omotion can be used as live fail-over option on Oracle VM without
incurring additional CPU license penalties. RAC One Node is certied and supported
with Oracle VM. RAC One Node continually monitors the status of a Database running
inside a virtual machine, and if the RAC One Node instance experiences a catastrophic
failure, RAC One Node will restart the aected database in place or on another standby
RAC One Node virtual machine. Following the Oracle Software Investment Guide (SIG)
failover rule, a standby RAC One Node virtual machine can run an Oracle Database
without additional licensing fees for up to 10 days in any calendar year.
Figure 7 shows how hard partitioning with Oracle VM can be used with RAC One Node
to gain total control over processor licensing costs.
Note: The 10-day rule applies to Oracle products using failover technologies in an
active/passive cluster. With Oracle products in an active/passive cluster, if a primary
node fails, failover to a second node for up to 10 days in any calendar year is permitted
without additional license fees.
13 of 27
http://mokumsolutions.com
14 of 27
http://mokumsolutions.com
Before you pin a virtual machine's CPUs to an Oracle VM Server's CPU cores, its
necessary to understand the Oracle VM Server's CPU topology to be able to pin a
virtual machine's CPUs to the desired Oracle VM Server's CPU cores and/or threads.
There are a number of commands to list an Oracle VM Server's CPU topology.
dmidecode and xenpm are my favorite commands to map out an Oracle VM Server's
CPU topology. dmidecode is a tool that reports information about a system's hardware
as described in the system BIOS. As root, type "man dmidecode" to print the dmidecode
man page. xenpm stands for Xen Power Management. Xenpm is a userspace program
that lists CPU power information and provides control over power policies. Type xenpm
or xenpm --help to print the xenpm command list.
To gain a clear picture of an Oracle VM Server's CPU topology, as root, type "dmidecode
-t 4 | grep CPU" to list the system' CPU details. Next, as root, type xenpm get-cputopology to list the CPU topology. The details from dmidecode and xenpm get-cputopology will allow you to generate a CPU pinning plan showing the
mapping between virtual machine CPUs to Oracle VM Server CPU cores.
The next example shows the CPU topology of an Oracle VM Server with Quad (4),
Octo-core (8) CPUs, with hyper-threading enabled. The example server has 32 CPU
cores with an Oracle processor factor of 16, i.e. 16 CPU licenses. Virtual machine CPUs
can be pinned from 1 up to 16 of CPU licenses.
Table 2 shows the example servers processor factor, cores, threads, and virtual machine
pinning and NUP options.
Sockets/CPUs
Cores
32
Threads
64
Processor
Factor
16 CPU
Licenses
VM Pinning Options
1 CPU License = 2 Cores
= 4 Threads = 4 vCPUs
2 CPU License = 4 Cores
= 8 Threads = 8 vCPUs
3 CPU License = 6 Cores
= 12 Threads = 12
vCPUs
4 CPU License = 8 Cores
= 16 Threads = 12
vCPus
5 CPU License =
10 Cores = 20 Threads
= 20 vCPUs
6 CPU License =
12 Cores = 24 Threads
= 24 vCPUs
7 CPU License =
14 Cores = 28 Threads
= 28 vCPUs
8 CPU License =
16 Cores = 32 Threads
= 32 vCPUs
9 CPU License =
18 Cores = 36 Threads
= 36 vCPUs
10 CPU License =
20 Cores = 40 Threads
= 40 vCPus
11 CPU License =
22 Cores = 44 Threads
= 44 vCPUs
12 CPU License =
24 Cores = 48 Threads
DB NUPs
25 users per
processor
10 users per
processor
15 of 27
http://mokumsolutions.com
= 48 vCPU
13 CPU License =
26 Cores = 52 Threads
= 52 vCPUs
14 CPU License =
28 Cores = 56 Threads
= 56 vCPUs
15 CPU License =
30 Cores = 60 Threads
= 60 vCPUs
16 CPU License =
32 Cores = 64 Threads
= 64 vCPUs
16 of 27
http://mokumsolutions.com
CPU17
CPU18
CPU19
CPU20
CPU21
CPU22
CPU23
CPU24
CPU25
CPU26
CPU27
CPU28
CPU29
CPU30
CPU31
CPU32
CPU33
CPU34
CPU35
CPU36
CPU37
CPU38
CPU39
CPU40
CPU41
CPU42
CPU43
CPU44
CPU45
CPU46
CPU47
CPU48
CPU49
CPU50
CPU51
CPU52
CPU53
CPU54
CPU55
CPU56
CPU57
CPU58
CPU59
CPU60
CPU61
CPU62
CPU63
0
1
1
2
2
3
3
4
4
5
5
6
6
7
7
0
0
1
1
2
2
3
3
4
4
5
5
6
6
7
7
0
0
1
1
2
2
3
3
4
4
5
5
6
6
7
7
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
Once you have the Oracle VM servers CPU topology, you can pin a virtual machines
17 of 27
http://mokumsolutions.com
CPUs to any of the Oracle VM Server's cores. A best practice is to follow the default
behavior of the credit scheduler and pin each of the virtual machine CPUs to a separate
physical core.
From an Oracle CPU licensing perspective, Hyper-threading does not increase the CPU license count of an
Oracle VM Server or a pinned virtual machine. Enabling Hyper-threading will increase the overall CPU
capacity of an Oracle VM Server and its virtual machines. For example, without hyper-threading, an Oracle
VM Server or virtual machine is only running a single thread per core. With hyper-threading, the number of
cores increases, and the Oracle VM Server or virtual machine can use the additional threads without
incurring additional Oracle CPU licensing penalties.
The next example shows the CPU topology of an Oracle VM Server with Dual (2),
Quad-core (4) CPUs, without hyper-threading enabled. The example server has 8 CPU
cores with an Oracle processor factor of 4, i.e. 4 CPU licenses. Virtual machine CPUs
can be pinned from 1 up to 4 of CPU licenses.
Table 2 shows the example servers processor factor, cores, threads, and virtual machine
pinning and NUP options.
Sockets/CPUs
Cores
Threads
NA
Processor
Factor
VM Pinning
Options
DB NUPs
4 CPU
Licenses
1 CPU License = 2
Cores = 2 vCPUs
2 CPU License =
4 Cores = 4 vCPUs
3 CPU License =
6 Cores = 6 vCPUs
4 CPU License =
8 Cores = 8 vCPus
25 users per
processor
10 users per
processor
18 of 27
http://mokumsolutions.com
CPU6
CPU7
3
4
1
1
1
1
Once you have the Oracle VM servers CPU topology, you can pin a virtual machines
CPUs to any of the Oracle VM Server's cores. A best practice is to follow the default
behavior of the credit scheduler and pin each of the virtual machine CPUs to a separate
physical core.
19 of 27
http://mokumsolutions.com
20 of 27
http://mokumsolutions.com
ovm_vmmessage
The Oracle VM utilities are available as a patch download from My Oracle Support. As of this writing
the latest release is My Oracle Support patch 13602094 (p13602094_30_Linux-x86-64.zip). The
p13602094_30_Linux-x86-64.zip le contains two les, ovm_utils_1.0.2.zip and readme.txt. Once
downloaded, unzip p13602094_30_Linux-x86-64.zip on the Oracle VM Manager host.
# unzip p13602094_30_Linux-x86-64.zip
Archive: p13602094_30_Linux-x86-64.zip
extracting: ovm_utils_1.0.2.zip
inating: readme.txt
Tip: If a previous version of the Oracle VM utilities are already installed, Oracle recommends to delete
the previous version, i.e. "cd /u01/app/oracle/ovm-manager-3/", then "rm -rf ./ovm_utils", before
installing the new version.
Next, unzip p13602094_30_Linux-x86-64.zip in the /u01/app/oracle/ovm-manager-3 directory.
# unzip ovm_utils_1.0.2.zip -d /u01/app/oracle/ovm-manager-3/
Archive: ovm_utils_1.0.2.zip
creating: /u01/app/oracle/ovm-manager-3/ovm_utils/
creating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/
creating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_vmcontrol.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_vmhostd.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_logger.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_vmdisks.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_reporestore.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_poolcontrol.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_managercontrol.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_vmmessage.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_servercontrol.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/man/man8/ovm_repocontrol.8
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_logger
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_repocontrol
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_vmdisks
creating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmVmMessage.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmLogger.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmRepoRestore.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmVmHostd.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmRepoControl.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmVmControl.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmVmDisks.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmServerControl.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmCoreControl.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/class/OvmPoolControl.class
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_vmcontrol
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_managercontrol
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_vmhostd
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/vm-dump-metrics
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/ovm_reporestore
creating: /u01/app/oracle/ovm-manager-3/ovm_utils/lib/
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/lib/log4j.jar
inating: /u01/app/oracle/ovm-manager-3/ovm_utils/lib/OvmClient.jar
21 of 27
http://mokumsolutions.com
inating:
inating:
inating:
inating:
/u01/app/oracle/ovm-manager-3/ovm_utils/lib/commons-logging.jar
/u01/app/oracle/ovm-manager-3/ovm_utils/ovm_servercontrol
/u01/app/oracle/ovm-manager-3/ovm_utils/ovm_poolcontrol
/u01/app/oracle/ovm-manager-3/ovm_utils/ovm_vmmessage
The man pages for the Oracle VM utilities are in the ovm_utils/man/man8 directory. Since the Oracle
VM utilities man pages are not in the default man path, it is necessary to type "man
path_to_man_page to read each man page. The following example shows how to read each of
the Oracle VM utilities man pages.
-rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--rw-r--r--
1
1
1
1
1
1
1
1
1
1
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
root
Before you pin a virtual machine's CPUs to an Oracle VM Server's CPU cores, it is necessary to understand the
Oracle VM Server's CPU topology. There are a number of commands to list an Oracle VM Server's CPU
topology. The xenpm command is my favorite command, xenpm stands for Xen Power Management. Xenpm is
a userspace program that lists CPU power information and provides control over power policies. Type xenpm
or xenpm --help to print the xenpm command list.
The next exmple shows the CPU topology from the Oracle VM Server used through this
section. The example Oracle VM Server has 1 CPU, 4 cores with hyperthreading
enabled.
# xenpm get-cpu-topology
CPU
core socket node
CPU0
0
0
0
CPU1
0
0
0
CPU2
1
0
0
CPU3
1
0
0
CPU4
2
0
0
CPU5
2
0
0
CPU6
3
0
0
CPU7
3
0
0
The next example shows how to query the CPU pinning from a virtual machine named
yum-chekov. Substitute admin with your Oracle VM Manager user account, password
with your admin user account password, and yum-chekov with the name of your virtual
machine, i.e. the name displayed in Oracle VM Manager.
Run ovm_vmcontrol from the Oracle VM Manager host:
./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuget
Oracle VM VM Control utility 0.5.2.
Connected.
22 of 27
http://mokumsolutions.com
Command : vcpuget
Virtual Machine 'yum-sulu' has no pinned vcpus.
The above example shows that the virtual machine is not pinned.
The next example shows how to pin both CPUs to core 0. Run ovm_vmcontrol from the
Oracle VM Manager host.
# ./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuset -s 0
Oracle VM VM Control utility 0.5.2.
Connected.
Command : vcpuset
Pinning virtual CPUs
Pinning of virtual CPUs to physical threads '0' 'yum-chekov' completed.
To conrm CPU pinning, access the Oracle VM Server running the pinned virtual
machine, (Oracle VM Manager shows which server virtual machines are running on and
the virtual machine's UUID/name), and as root type "xm vcpu-list Domain ID or
UUID". The next example shows the output from "xm vcpu-list Domain ID or UUID"
for yum-chekov. Replace 0004fb0000060000dbf90ab3718822c0 with your virtual
machines name or ID, i.e. type xm list to list the running virtual machines on a host.
# xm vcpu-list 0004fb0000060000dbf90ab3718822c0
Name
ID VCPU CPU State Time(s) CPU Anity
0004fb0000060000dbf90ab3718822c0 41
0
0 -b17.0 0
0004fb0000060000dbf90ab3718822c0 41
1
0 -b40.4 0
The next example shows how to pin both CPUs to core 0 and 3. Run ovm_vmcontrol
from the Oracle VM Manager host.
# ./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuset -s 0,3
Oracle VM VM Control utility 0.5.2.
Connected.
Command : vcpuset
Pinning virtual CPUs
Pinning of virtual CPUs to physical threads '0,3' 'yum-chekov' completed.
To conrm CPU pinning, access the Oracle VM Server running the pinned virtual
machine, (Oracle VM Manager shows which server virtual machines are running on and
the virtual machine's UUID/name), and as root type "xm vcpu-list Domain ID or
UUID". The next example shows the output from "xm vcpu-list Domain ID or UUID"
for yum-chekov. Replace 0004fb0000060000dbf90ab3718822c0 with your virtual
machines name or ID, i.e. type xm list to list the running virtual machines on a host.
# xm vcpu-list 0004fb0000060000dbf90ab3718822c0
Name
ID VCPU CPU State Time(s) CPU Anity
0004fb0000060000dbf90ab3718822c0 41
0
0 -b17.3 0,3
0004fb0000060000dbf90ab3718822c0 41
1
3 -b40.5 0,3
23 of 27
http://mokumsolutions.com
The next example shows how to pin both CPUs to core 1 and 2. Run ovm_vmcontrol
from the Oracle VM Manager host.
# ./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuset -s 1,2
Oracle VM VM Control utility 0.5.2.
Connected.
Command : vcpuset
Pinning virtual CPUs
Pinning of virtual CPUs to physical threads '1,2' 'yum-chekov' completed.
To conrm CPU pinning, access the Oracle VM Server running the pinned virtual
machine, (Oracle VM Manager shows which server virtual machines are running on and
the virtual machine's UUID/name), and as root type "xm vcpu-list Domain ID or
UUID". The next example shows the output from "xm vcpu-list Domain ID or UUID"
for yum-chekov. Replace 0004fb0000060000dbf90ab3718822c0 with your virtual
machines name or ID, i.e. type xm list to list the running virtual machines on a host.
# xm vcpu-list 0004fb0000060000dbf90ab3718822c0
Name
ID VCPU CPU State Time(s) CPU Anity
0004fb0000060000dbf90ab3718822c0 41
0
2 -b17.4 1-2
0004fb0000060000dbf90ab3718822c0 41
1
1 -b40.7 1-2
24 of 27
http://mokumsolutions.com
25 of 27
http://mokumsolutions.com
Listing the above virtual machine CPU pinning with ovm_vmcontrol would show that the
virtual machine is not pinned. The next example shows the output from ovm_vmcontrol
on an unpinned virtual machine.
./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuget
Oracle VM VM Control utility 0.5.2.
Connected.
Command : vcpuget
Virtual Machine 'yum-sulu' has no pinned vcpus.
The next vm.cfg example shows a new line in the vm.cfg le, cpus = '1,2'. The cpus =
'1,2' entry shows that the virtual machines CPUs are pinned to the Oracle VM servers
CPU cores 1 and 2. The following example vm.cfg CPU pinning was set by typing the
following command:
# ./ovm_vmcontrol -u admin -p password -h localhost -v yum-chekov -c vcpuset -s 1,2
Oracle VM VM Control utility 0.5.2.
Connected.
Command : vcpuset
Pinning virtual CPUs
Pinning of virtual CPUs to physical threads '1,2' 'yum-chekov' completed.
Please note the vcpus = 2 entry, one line above the cpus = '1,2' entry. The vcpus = 2
entry denes the allocated number of CPUs.
# vi /OVS/Repositories/0004fb000003000000c6307a0210108c/VirtualMachines
/0004fb0000060000dbf90ab3718822c0/vm.cfg
vif = ['mac=00:21:f6:00:00:52,bridge=0004fb001025f15',
'mac=00:21:f6:00:00:69,bridge=192.168.3.0']
OVM_simple_name = 'yum-chekov'
disk = ['le:/OVS/Repositories/0004fb000003000000c6307a0210108c/VirtualDisks
/0004fb00001200001715425de783bb2a.img,xvda,w', 'le:/OVS/Repositories
/0004fb000003000000c6307a0210108c/VirtualDisks
/0004fb0000120000b400de1a5c40d6dc.img,xvdb,w', 'le:/OVS/Repositories
/0004fb000003000000c6307a0210108c/VirtualDisks
/0004fb00001200005266f7966823c7c8.img,xvdc,w']
uuid = '0004fb00-0006-0000-dbf9-0ab3718822c0'
on_reboot = 'restart'
boot = 'c'
cpu_weight = 27500
memory = 1024
cpu_cap = 0
maxvcpus = 2
OVM_high_availability = True
maxmem = 1024
timer_mode = 0
OVM_description = ''
on_powero = 'destroy'
26 of 27
http://mokumsolutions.com
on_crash = 'restart'
bootloader = '/usr/bin/pygrub'
name = '0004fb0000060000dbf90ab3718822c0'
guest_os_type = 'linux'
vfb = ['type=vnc,vncunused=1,vnclisten=127.0.0.1,keymap=en-us']
vcpus = 2
cpus = '1,2'
OVM_os_type = 'Oracle Linux 5'
OVM_cpu_compat_group = None
OVM_domain_type = 'xen_pvm'
:wq!
The above example vm.cfg le shows a hard partitioned virtual machine with two CPUs
using 1 Oracle processor license. The virtual machines CPUs are pinned to the Oracle
VM Servers CPU cores 1 and 2.
27 of 27