Escolar Documentos
Profissional Documentos
Cultura Documentos
Acceleration
Discovery Day
Oracle on Solaris:
Tips, Tricks &
Best Practices
Andreas Neuhold
Commercial Products Sales Lead
Sun Microsystems
1
Agenda
> Orac
le & S o
laris : #
1
> Orac
le D B o
n Solar
is
> Orac
le DB i n
Contain
> Orac ers
le in C o
ntainer
> Res
C lusters
ources
2
Source: Oracle + Sun Strategy Webcast 3
Number of Unique Customers Entering Tars for
Mainstream Unix Platforms –
2H FY2007, 2H FY2008, 2H FY2009
8000
7000
6000
5000
4000 2H2007
3000 2H2008
2000 2H2009
1000
0
Solaris SPARC Solaris x64 HP-UX ItaniumHP-UX PA-RISC AIX 64
64
4
Percentage of UNIX Customers for mainstream UNIX
platforms per Service Request – 2HFY2009
Solaris SPARC
Solaris x64
27%
36%
HP-UX Itanium
5
Agenda
> Orac
le & S o
laris : #
1
> Orac
le D B o
n Solar
is
> Orac
le DB i n
Contain
> Orac ers
le in C o
ntainer
> Res
C lusters
ources
6
• Oracle DB on Solaris – based on
7
Oracle on Solaris
• Solaris 10 is the #1 UNIX platform for Oracle
deployments
• Solaris benefits from many years of performance
enhancements designed to benefit Oracle
• Solaris offers outstanding -
8
More than 15 years of joint
Solaris/Oracle DBMS Optimizations
• Intimate Shared Memory (1993) /
Dynamic Intimate Shared Memory (2002)
• Scheduler control optimizations (1997)
• 64-bit memory space (1998)
• /dev/poll (1998)
• Reconfiguration Coordination Manager (2002)
• Locality Groups (2002)
• Large Page Support (2002, 2005)
• FX – Fixed Priority Class (2002)
• Direct IO with concurrent writes (2002)
• Sun Cluster optimizations for Oracle RAC (multiple)
http://wikis.sun.com/display/Performance/Key+Sun+technologies+for+running+Oracle
9
The Dark Underbelly of DB Workloads:
Data Stalls
• Data stalls dominate execution time
> 46%-64% of execution time wasted on data stalls
> True for both OLTP and DSS database workloads
> Even more execution time wasted on instruction stalls
> Especially for OLTP, where you waste a further 10%-15%
10
Everything Changes with Sun's
CoolThreads CMT Systems
• Data stalls drop to 13%
> 76%-80% of execution time spent on usefull computation
> True for both OLTP and DSS database workloads
> Instruction stalls are negligible
> END RESULT: 70% higher throughput than traditional systems
11
A Simple Analogy: Cars are Good!
12
Buses are good, too
13
Oracle Performance Expectations
• Most OLTP environments run very well with CMT
> Understand response time components
> DB CPU usually around 20% of response time
> IO, Network, and application tier makes up the rest
• Bad code is a bottleneck on any server
> CPU-bound bad code bites you sooner on CMT servers
• Serial Batch jobs run slower with CMT
> Check the usual suspects
> Execution Plans, Indexes, Business Logic
> Divide and Conquer
> Increase Concurrency and Parallelism
14
Oracle on SPARC Servers – Summary
• Sun's CMT Server Advantages
> Low power consumption
> Maximum rack computational density
> Logical Domains (LDoms) powerful and bundled (by use of Solaris 10)
• Sun's M-Series Server Advantages
> Outstanding scalability
> Enterprise-class RAS features
> Flexible domaining
• Solaris Containers run on both CMT and M-Series
> Secure virtual OS instances, negligible perf overhead
> Capped Containers recognized for licensing purposes
15
Best Practices Categories
• Avoiding known performance bugs
> Some are surprisingly high-impact
> Architecturally-dependent factors are not widely-known
• Copying proven patterns, avoiding known antipatterns
> Filesystem and network choices
> “Big knob” tunables
> Platform- or application-specific settings (some not widely-known)
• In general, being disciplined about performance
> Holistically, including the application code, solution architectures, operational
plans, backup and recovery, business continuance
> Methods, tools, interdisciplinary and interdepartmental alignment, frameworks,
metrics, processes
NOTE: While there is no clear objective line between “Best Practices” and “tuning” - the distinction is much
like how “just do it” relates to “optimization”. Both may be needed to meet system performance objectives.
16
Oracle Performance Bugs & Patches
• 10.2.0.4 is a Good Place to be, with these fixes (among others) ...
> Bug #6814520 - Compute efficiency of block checksum code on SPARC was
very poor
> Bug #5752399 - For enabling direct I/O on certain filesytems,
filesystemio_options=setall was broken
17
Filesystem/Feature Selection
• Performance Best Practice: use an unbuffered, concurrent I/O stack and
consistent contiguous ondisk data placement
18
Control LGWR Priority on Purpose
• Run LGWR at Fixed Priority (FX) 60, even when FSS is in use
> Otherwise, TS scheduling will reduce its priority when it gets busy -
exactly opposite of what one would want!
• Other background processes may also benefit from special
scheduling, but LGWR is uniquely critical path to all
transactions
• This is especially important on systems with high aggregate
CPU utilization or systems with slower single-thread speeds
19
RAC: Use Jumbo Frames!
• Jumbo frames delivers multiple benefits
> Reduces GC latency
> Reduces CPU utilization, %sys, and hardware interrupts
> Avoids scaling challenges of IP packet reassembly
> Radically improves scaling of RAC on CMT CPUs
• Implementation notes
> Oracle specifies dedicated interconnects for RAC; jumbo frames should not be
an 'infrastructure project'
• See also
> http://blogs.sun.com/glennf/entry/jumbo_frames_with_oracle_rac
20
For more information
Check out the Sun Performance Wiki!
> For Sun Performance information generally
http://wikis.sun.com/display/performance
21
Agenda
> Orac
le & S o
laris : #
1
> Orac
le D B o
n Solar
is
> Orac
le DB i n
Contain
> Orac ers
le in C o
ntainer
> Res
C lusters
ources
22
Whitepaper
23
Solaris Containers
• Provide a virtual OS environment for applications; ideal for
consolidation, e.g. Oracle Dbs
24
Solaris 10 Container
• OS Virtualization
> One single OS installation
> Multiple runtime environments, appear
Database
System
App as “regular” Solaris OS to applications
Appl.Srv.
and users
Container Container Container
• Flexible, software-defined boundaries
OS > “Can't see outside zone”
> “Can't affect activity outside zone”
• Simple isolation
Server > Network, disks, memory, CPU,
processes, environment
• Each Container has it's own identity
(/etc/...)
27
Solaris Containers
A convenient virtual platform for Oracle Part2
Solaris 10 Containers have unique features, valuable especially in
Oracle environments !!
• Scalable
> Up to 8192 Container. Nearly no performance degradation. (SAP Benchmark:
1,25% for 4 Containers).
• Platform Support
> Available for all Solaris 10 platforms: Intel, AMD, UltraSPARC on Sun, Dell,
HP, IBM, Fujitsu/Siemens and more ...
• Oracle Support
> Oracle does support “single instance” in Solaris 10 Containers.
> New:
New Oracle will certify and support RAC in Solaris 10 Containers. (Status:
QA).
> Container (CPU pool or CPU cap) is accepted as Oracle license limitation.
• Proven
> Many customer references
28
Highly Available Solaris Containers
• Containers can be moved between Servers
• Containers can be made HA using Oracle Solaris Cluster
29
Agenda
> Orac
le & S o
laris : #
1
> Orac
le D B o
n Solar
is
> Orac
le DB i n
Contain
> Orac ers
le in C o
ntainer
> Res
C lusters
ources
30
Blueprint
31
Container Clusters - why
32
Oracle Solaris Container Cluster
Best Environment For Multi-tier Deployments
Node 1 Node 2 Node 3 Node 4
Finance
Finance Finance Container
Cluster with
RAC 10g Application fault isolation
Security isolation
Sales
Container Sales Sales Consolidation use cases
Cluster with
RAC 10g • Multiple Oracle RAC
databases
Engineering Engineering • Test & Development
Engineering Container Engineering Engineering
databases
Cluster with
RAC 11g • Multiple data center tier /
multiple application
33
Agenda
> Orac
le & S o
laris : #
1
> Orac
le D B o
n Solar
is
> Orac
le DB i n
Contain
> Orac ers
le in C o
ntainer
> Res
C lusters
ources
34
Resources
• Cool Tools
> http://cooltools.sunsource.net/
• Blueprints
> http://wikis.sun.com/display/BluePrints/Main
• CoolThreads Experts Q&A Portal
> http://www.sun.com/secure/servers/coolthreads/tnb/contact.jsp
• Performance Wiki
> http://wikis.sun.com/display/performance
• Blogroll
> Glenn Fawcett - http://blogs.sun.com/glennf
> Denis Sheahan - http://blogs.sun.com/deniss
> Tanel Poder - http://blog.tanelpoder.com
> Greg Rahn - http://structureddata.org
> Bob Sneed - http://blogs.sun.com/bobs (paused)
> Allan Packer - http://blogs.sun.com/allanp
35
Oracle Database
Acceleration
Discovery Day
Oracle on Solaris:
Tips, Tricks &
Best Practices
Andreas Neuhold
andreas.neuhold@sun.com
36