Tips and Tricks for Tuning - PowerPoint PPT Presentation

1 / 47
About This Presentation
Title:

Tips and Tricks for Tuning

Description:

Tuning the Cartridge processes. Oracle Application Server Tuning adds a new layer to the ... Cartridge and Listener Tuning. Balance load by configuring ... – PowerPoint PPT presentation

Number of Views:32
Avg rating:3.0/5.0
Slides: 48
Provided by: Hon148
Category:

less

Transcript and Presenter's Notes

Title: Tips and Tricks for Tuning


1
Tips and Tricks for Tuning Your Web Environment
Shankaran Iyer Renaissance Worldwide
Inc. Bloomington, Minnesota siyer_at_rens.com www.ren
s.com
2
Objectives
Review Oracle Web Application Architecture
Examine special tuning requirements for Oracle
web deployment Provide tuning
recommendations Suggest steps to sustain
application performance
3
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
4
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
5
Web Applications Architecture

6
Web Applications Architecture
7
Web Applications Architecture
Tuning Methodology for Application Server is a
bit different compared to the Application or
Database Tuning

Similarities
Monitor and Tune memory, CPU and disk I/O
utilization General tuning of the database
server
8
Web Applications Architecture
Differences

More detailed network bandwidth utilization
analysis Monitoring and Tuning the Web
listeners Tuning the Cartridge processes
Oracle Application Server Tuning adds a new layer
to the overall Database Performance Tuning
Methodology.
9
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
10
Web Tuning Tips
Tuning the Oracle Application Server
Tip Closely monitor the size of the log files
- Watch for errors in the log files and regularly
fix them - Develop an archive-and-rollover
process. - Use logs to determine average and
maximum hits to your application.
11
Web Tuning Tips
Tuning the Oracle Application Server
Tip For small applications use the same server
as Application Server and Database
Server
- To avoid SQLNet (Net8) traffic, keep the
application and database on the same server -
Consider this architecture for low number of hits
or for pilot projects.
12
Web Tuning Tips
Tuning the Oracle Application Server
Tip Estimate the average number of concurrent
users
- Estimate the minimum and maximum users using
the application. - Use these numbers to setup
cartridge processes.
13
Web Tuning Tips
Tuning the Oracle Application Server
Tip Make sure that the Application Server has
sufficient free memory
- Cartridges processes requires anywhere between
5 Meg to 14 Meg of memory per user. - Estimate
and plan for large amount of memory.
14
Web Tuning Tips
Tuning the Oracle Application Server
Tip Use IP address instead of server name for
connecting to the Database Server
15
Web Tuning Tips
Tuning the Oracle Application Server
Tip Set the PL/SQL Cartridge configuration
parameters
- For Version 3.0.1.8.1 set
OWS_ORAWEB_MINMAX 300 OWS_BROKER_BHFREQ
300 - This ensures that idle PL/SQL processes are
killed less often.
16
Web Tuning Tips
Tuning the Oracle Application Server
Tip Monitor CPU utilization, memory, swapping
and paging
- The web listeners should always be TOP CPU
consuming processes. - On UNIX use utilities
like sar, top, glance etc. - Swap space should
not exceed 70 of allocated.
17
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
18
Web Tuning Tips
Network Tuning
First look for network bandwidth
utilization. Tune certain TCP parameters
- On HP to get help on tunable tcp parameters
nettune -h tcp nettune tcpkeepfreq / shows
curr val / nettune -l tcpkeepfreq / show range
/ nettune -s tcpkeepfreq 2000 / sets value /

19
Web Tuning Tips
Processor Utilization
Web listener processes should be top CPU
consumers Use flow chart to analyze CPU
bottlenecks and take corrective action
20
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
21
Web Tuning Tips
Cartridge and Listener Tuning
Tip Pin web packages to SGA.
- Find sub-programs consuming maximum memory
SELECT owner, type, name, sharable_mem FROM
vdb_object_cache WHERE type in
(PROCEDURE,PACKAGE, PACKAGE
BODY) ORDER BY sharable_mem desc
22
Web Tuning Tips
Cartridge and Listener Tuning
Tip Pin web packages to SGA (continued)
- Find sub-programs frequently used by your
users SELECT owner, type, name, executions
FROM vdb_object_cache WHERE type in
(PROCEDURE,PACKAGE, PACKAGE
BODY) ORDER BY executions desc
23
Web Tuning Tips
Cartridge and Listener Tuning
Tip Pin web packages to SGA.
- Pin packages and procedures that are frequently
used. - For pinning use the command, EXECUTE
dbms_shared_pool.keep(ORACLEAPPS)
24
Web Tuning Tips
Cartridge and Listener Tuning
Balance load by configuring multiple
listeners Keep the number of database
connections in owa.cfg to a minimum
Use multi-threaded server option to configure
database
25
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
26
Web Tuning Tips
Database Server Tuning
Tip Perform general database server tuning
Database Reorganization, avoid row-chaining
Rollback Segment contention Avoid I/O
bottlenecks
27
Web Tuning Tips
Database Server Tuning
Tip Increase SHARED_POOL_SIZE. Increase
the size of your SYSTEM tablespace
- should hold all procedures, triggers, functions
and PL/SQL blocks oversize leads to
fragmentation - starting size could be 40-50M -
can be determined based on a study of maximum
utilization and number of concurrent users.
28
Web Tuning Tips
Database Server Tuning
Tip Cache frequently used tables
Use the command ALTER TABLE lttable-namegt CACHE
29
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
30
Web Tuning Tips
Database Server Tuning
Monitor memory and swap space on Application
Server and Database Server
31
Web Application Scalability
Capacity Planning Issues
1. How many more users can I add before I see a
dip in the performance 2. What are the
things to be considered when planning a
large web rollout 3. Identify need for stress
testing 4. Architecture related issues
32
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
33
Web Application Scalability
Web Scalability Tips
Plan for adequate resources for concurrent
users
Determine - number of users using the
application - estimate time they will be
using the application - statistics on
parallel use
34
Web Application Scalability
Web Scalability Tips
Monitor and Tune Network, CPU and Memory.
- Fixed and Variable Memory - Variable portion
scales linearly based on number of concurrent
hits
35
Web Application Scalability
Web Scalability Tips
Scalability Options
Option 1 Add more memory,CPU to the same
server Option 2 Add additional application
server for increasing user loads
(Recommended) Option 3 Use load balancing
hardware/software
36
Web Application Scalability
Web Scalability Tips
Stress Testing
- Recommended for large applications - Ensure
your application runs efficiently in your
environment. - Use Stress Testing Tools
37
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
38
Web Application Scalability
Architecting for Scalability
Add additional Application Server for larger
volumes to sustain throughput.
39
Web Application Scalability
Architecting for Scalability
Configuring multiple application server helps
load balancing Reduces contention between
application server and database server
40
Web Application Scalability
Architecting for Scalability
Decide on number of listeners based on number
of cartridges and application load
41
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
42
Top-5 Performance Recommendations
1. Accurately estimate and tune the MIN and MAX
connections for various cartridges based on
average number of users, concurrently using the
app. 2. Pin web packages to make them SGA
resident and also tune certain init.ora
parameters. 3. Write scripts to monitor resource
consumption by the web user processes. 4.
Monitor CPU usage, memory consumption, tune TCP
parameters, inspect the web listener log files
periodically. Keep log file size low. 5.
Perform general database tuning including
defragmentation.
43
Agenda
Web Applications Architecture Web Tuning
Tips gtgt Tuning the Oracle Application
Server gtgt Network Tuning gtgt
Cartridge and Listener Tuning gtgt
Database Server Tuning Web Application
Scalability gtgt Capacity Planning Issues
gtgt Web Scalability Tips gtgt
Architecting for Scalability Top-5 Performance
Recommendations Conclusion
44
To Summarize...
Oracle Application Server provides a good
platform for deploying scalable applications.
Thorough monitoring and tuning can improve
performance of Oracle web-based applications.
45
Questions !
46
About
Global IT and Management consulting 100
offices globally, 6500 consultants/experts
Headquarters _at_ Newton, Boston.
Minneapolis Branch
Consulting services in areas like E-commerce,
Test and QA, Database, Network Services and
Client Server Development Services 250 Staff
and Hourly consultants Laura Miller, Branch
Manager 612-851-3615 lmiller_at_rens.com
47
About the Author
Shankaran Iyer has been working with Oracle
Server and Tools for over 11 years. He provides
consulting on Performance Audit, data warehousing
and technical DBA and web deployment
issues. Shankaran is working with Renaissance
Worldwide Inc. in Minneapolis as Technology
Manager. He can be reached at (612)851-3160.
His email is siyer_at_rens.com
Write a Comment
User Comments (0)
About PowerShow.com