Scaling DB2 9.7 in a Red Hat Enterprise Linux 5.4-KVM environment.pdf

(527 KB) Pobierz
Scaling DB2 9.7 in a Red Hat
Enterprise Virtualization
Environment
OLTP Workload
DB2 9.7
Red Hat
®
Enterprise Linux 5.4 Guest
Red Hat
®
Enterprise Linux 5.4
(with Integrated KVM Hypervisor)
®
HP ProLiant DL370 G6
(Intel Xeon W5580 - Nehalem)
Version 1.0
October 2009
Scaling DB2 in a Red Hat
®
Virtualization Environment
1801 Varsity Drive
Raleigh NC 27606-2072 USA
Phone: +1 919 754 3700
Phone: 888 733 4281
Fax: +1 919 754 3701
PO Box 13588
Research Triangle Park NC 27709 USA
Linux is a registered trademark of Linus Torvalds.
Red Hat, Red Hat Enterprise Linux and the Red Hat "Shadowman" logo are registered trademarks of
Red Hat, Inc. in the United States and other countries.
IBM, the IBM logo, System x, DB2 and all other IBM products and services mentioned herein are
trademarks or registered trademarks of IBM Corporation in the United States and other countries.
All other trademarks referenced herein are the property of their respective owners.
© 2009 by Red Hat, Inc. This material may be distributed only subject to the terms and conditions set
forth in the Open Publication License, V1.0 or later (the latest version is presently available at
http://www.opencontent.org/openpub/).
The information contained herein is subject to change without notice. Red Hat, Inc. shall not be liable
for technical or editorial errors or omissions contained herein.
Distribution of modified versions of this document is prohibited without the explicit permission of Red
Hat Inc.
Distribution of this work or derivative of this work in any standard (paper) book form for commercial
purposes is prohibited unless prior permission is obtained from Red Hat Inc.
The GPG fingerprint of the security@redhat.com key is:
CA 20 86 86 2B D6 9D FC 65 F6 EC C4 21 91 80 CD DB 42 A6 0E
www.redhat.com
2
Table of Contents
1 Executive Summary................................................................................................................4
1.1 DB2 9.7............................................................................................................................5
2 Red Hat Enterprise Virtualization (RHEV) - Overview............................................................6
2.1 Red Hat Enterprise Virtualization (RHEV) - Portfolio......................................................6
2.2 Kernel-based Virtualization Machine (KVM)....................................................................8
2.2.1 Traditional Hypervisor Model...................................................................................9
2.2.2 Linux as a Hypervisor...............................................................................................9
2.2.3 A Minimal System...................................................................................................10
2.2.4 KVM Summary.......................................................................................................10
3 Test Configuration.................................................................................................................11
3.1 Hardware.......................................................................................................................11
3.2 Software.........................................................................................................................11
3.3 SAN................................................................................................................................12
4 Test Methodology..................................................................................................................13
4.1 Workload........................................................................................................................13
4.2 Configuration & Workload..............................................................................................13
4.3 Performance Test Plan..................................................................................................14
4.4 Tuning & Optimization...................................................................................................15
4.4.1 Processes...............................................................................................................15
4.4.2 I/O Scheduler.........................................................................................................15
4.4.3 Huge Pages............................................................................................................16
4.4.4 NUMA.....................................................................................................................17
4.4.5 Database Configuration and Tuning......................................................................18
5 Test Results..........................................................................................................................19
5.1 Scaling Multiple 2-vCPU Guests...................................................................................20
5.2 Scaling Multiple 4-vCPU Guests...................................................................................22
5.3 Scaling Multiple 8-vCPU Guests...................................................................................24
5.4 Scaling-Up the Memory and vCPUs in a Single Guest.................................................26
5.5 Consolidated Virtualization Efficiency............................................................................28
6 Conclusions...........................................................................................................................29
7 References............................................................................................................................29
Appendix A – Virtualization Efficiency (IOPS)..........................................................................30
3
www.redhat.com
1 Executive Summary
This paper describes the performance and scaling of DB2 9.7 running in Red Hat Enterprise
Linux 5.4 guests on a Red Hat Enterprise Linux 5.4 host with the KVM hypervisor. The host
was deployed on an HP ProLiant DL370 G6 server equipped with 48 GB of RAM and
comprising dual sockets each with a 3.2 GHz Intel Xeon W5580 Nehalem processor with
support for hyper-threading technology, totaling 8 cores and 16 hyper-threads (i.e., 8 cores
with hyperthreading are presented to the operating system as 16 logical CPUs).
The workload used was an IBM DB2 developed, customer-like Online Transaction Processing
(OLTP) workload.
Scaling Up A Virtual Machine
First, the performance of the DB2 OLTP workload was measured by loading a single DB2
guest on the server, and assigning it two, four, six, and eight virtual CPUs (vCPUs). The
performance results as observed in this paper indicate that DB2 9.7 running with KVM scales
near linearly as the VM expands from a single core with 2 hyper-threads to a complete 4 core/
8 hyper-thread server.
Scaling Out Virtual Machines
A second series of tests involved scaling out multiple independent VMs each comprised of
two, four or eight vCPUs, to a total of 16 vCPUs on an 8 core/16 hyper-thread Nehalem
server. Results show that the addition of DB2 guests scaled well, each producing proportional
increases in total amount of DB2 database transactions executed.
The data presented in this paper establishes that Red Hat Enterprise Linux 5.4 virtual
machines running DB2 9.7 using the KVM hypervisor on Intel Nehalem provide an effective
production-ready platform for hosting multiple virtualized DB2 OLTP workloads.
The combination of low virtualization overhead and the ability to both scale-up and scale-out
the guests contribute to the effectiveness of KVM for DB2. The number of actual users and
throughput supported in any specific customer situation will, of course, depend on the
specifics of the customer application used and the intensity of user activity. However, the
results demonstrate that in a heavily virtualized environment, good throughput was retained
even as the number and size of guests/virtual-machines was increased until the physical
server was fully subscribed.
www.redhat.com
4
1.1 DB2 9.7
DB2 version 9.7 is IBM’s fastest growing, flagship database offering. It comes equipped with
host dynamic resource awareness, automatic features such as Self-Tuning Memory
Management (STMM), automatic database tuning parameters, and enhanced automatic
storage, which greatly reduce administrative overhead for tuning and maintenance. These
functions including the threaded architecture make the DB2 product well suited for the
virtualization environment and enable it to leverage the KVM virtualization technology
efficiently.
The DB2 product works seamlessly in a virtualized environment, straight out of the box. DB2
recognizes and reacts to dynamic events or shifts in hardware resources, such as run time
changes to the computing and physical memory resources of a host partition. The STMM
feature automatically adjusts and redistributes DB2 memory in response to dynamic changes
in partition memory and workload conditions. Further automatic tuning parameters, and the
ability to change them dynamically without bringing the database instance down, enables DB2
to provide increased up-time and robust capabilities for mission critical database applications.
5
www.redhat.com
Zgłoś jeśli naruszono regulamin