Performance Testing Progress and Oracle
Environment Variables and Installation PUG Challenge Americas 2012 Performance Testing Progress and Oracle ProgressOracle DLC/usr/dlc102BORACLE_HOME/app/oracle/product/ ORACLE_BASE/app/oracle PATH$DLC/binPATH$ORACLE_HOME/bin To installproinstTo installrunInstaller Location/etc/oraInst.loc
Physical Structure (data files) PUG Challenge Americas 2012 Performance Testing Progress and Oracle Database Filesports.dbControl File(s)control01.ctl System Areasports.d1System Tablespacesystem.dbf D Filesarea.dDatafilestablespace.dbf Before-Image File + After-Image File sports.b1 + sports.a1 Undo tablespace + Redo Log undotbs.dbf + redo01.log Copy of After- Image File sports.date _time_etc Archive Logsports.date_time_ etc Structure filesports.stBackup of control file to trace file Log Filesports.lgAlert Logalert_sports.log Parameter Filesports.pfpfile (or spfile)initsports.ora
PUG Challenge Americas 2012 Performance Testing Progress and Oracle sports.db sports.d1 sports.lic sports.b1 sports.st sports_7.d1 sports_8.d1 sports_9.d1 sports.lg sports.pf control01.ctl cre_controlfile.sql redo01.log redo02.log redo03.log system01.dbf sysaux01.dbf temp01.dbf undotbs01.dbf users01.dbf.srt,.DBI ORACLE_HOME Physical Structure
Logical Structure PUG Challenge Americas 2012 Performance Testing Progress and Oracle AreaSchema AreaTablespaceSystem Tablespace Area consists of objects Objects are Tables or Indexes Tablespace consists of segments Segments: Tables, Indexes, Undo, etc Each Object has one or more Clusters Clusters size could be 8,64 or 512 blocks Each Segment has one or more Extents An extent is a series of blocks that are consecutively numbered within a datafile Clusters consist of blocks blocks 1,2,4 or 8KExtents consist of blocks blocks 2,4,8,16,32 or 64K
Background Processes PUG Challenge Americas 2012 Performance Testing Progress and Oracle Asynchronous Page WriterAPWDatabase WriterDBWn Before/After Image WriterBIW, AIWLog WriterLGWR AI ManagementAIMGTArchive ProcessARCn Watch DogWDOGProcess MonitorPMON Database Broker_mproservSystem MonitorSMON Checkpoint processCKPT Many other …. 20 at least Login Broker_mproservListenerlsnrctl
PUG Challenge Americas 2012 Performance Testing Progress and Oracle Client Server -db db_name -H host -S service Listener Shared memory -db /full_path/db-name N/A Login Brokerlsnrctl [start/stop/status] Connecting to a database $ORACLE_HOME/bin
PUG Challenge Americas 2012 Performance Testing Progress and Oracle -H host –S service1 -H host –S service2 S Host:port:SID SID Listener Port 1521 SID2 Connecting to a database Host:port:SID2
Meta-schema and VST PUG Challenge Americas 2012 Performance Testing Progress and Oracle Progress TableFieldOracle ViewColumn _Area_Area-nameDBA_TABLESPACESTABLESPACE_NAME _AreaExtent_Extent-PathDBA_DATA_FILESFILE_NAME _StorageObject_Object-type (1,2 or 3)DBA_OBJECTSobject_type (38 types) _File_File-nameDBA_TABLESTABLE_NAME _Field_Field-nameDBA_TAB_COLUMNSCOLUMN_NAME _Index_Index-nameDBA_INDEXESINDEX_NAME _Sequence_Seq-nameDBA_SEQUENCESSEQUENCE_NAME Progress Meta-schema tables -80 < _file-number < 0 Progress VST _file-number <
Meta-schema and VST PUG Challenge Americas 2012 Performance Testing Progress and Oracle Virtual System TablesV$ (Vee dollar) Views _Connectv$session, v$process _DbStatusv$instance, v$sysstat _Transv$transaction _Lockv$lock _Latchv$latch _AreaStatusv$tablespace _Filelistv$datafile _Startup (some)v$parameter
Data Types PUG Challenge Americas 2012 Performance Testing Progress and Oracle characterformat "x(100)"varchar2varchar2(100) decimalformat ">>>>9.99"numbernumber(7,2) integerformat ">>>>9"numbernumber(5) dateformat 99/99/9999date'MMDDYY HH24:MI:SS' logicalformat yes/noN/A datetimeHH:MM:SS.SSS+HH:MMtimestamp'HH24:MI:SS.FF5' int64format ">>>>9"numbernumber(38)
Create Database PUG Challenge Americas 2012 Performance Testing Progress and Oracle
Create Database prodb mydb procopy empty8 mydb Min size 5 MB Min memory 160KB Time to create 1 second A set of.sql scripts create database mydb; Min size 512 MB Min memory 512MB Time from 20 min to 1.5 hr PUG Challenge Americas 2012 Performance Testing Progress and Oracle
Shutdown Unconditional Shutdown Emergency Shutdown Shutdown Normal Shutdown Transactional Shutdown Immediate Shutdown Abort PUG Challenge Americas 2012 Performance Testing Progress and Oracle Progress 10.2B patch 06 -shutdownTimeout [ immed, 10m, 1h, maximum ]
Startup PUG Challenge Americas 2012 Performance Testing Progress and Oracle Closed Nomount mode Mount mode Open Prorest Restoreinit*.ora.ctl Shared Memory Background Proc
Backup PUG Challenge Americas 2012 Performance Testing Progress and Oracle Progress backup – simpleOracle RMAN – More complicated probkup db_name file_name Progress and Oracle : Online and Offline (Hot and Cold) Progress and Oracle : Complete and Incremental Oracle: could be Full and Partial
Compressed Backup PUG Challenge Americas 2012 Performance Testing Progress and Oracle 700 GB Progress DB makes about 600 GB probkup 1.4 TB Oracle DB makes either 1.2 TB regular backup or 250 GB RMAN compressed backup (BZIP2 is default).
Dump and Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Dictionary Dump and Load in ASCII format (.d) or 4GL export/import SQL select/insert “SQL Loader” or External Tables 10g Binary Dump (proutil –C dump)Oracle export (exp tables=tbl_name) Binary Load (proutil –C load)Oracle import (imp file=file_name) Binary Dump multithreaded V10Oracle Data Pump Export (expdp) 10g Oracle Data Pump Import (impdp) 10g Dump/Load.dfExport/Import (exp full=y rows=n)
ATM Database Tests PUG Challenge Americas 2012 Performance Testing Progress and Oracle Hardware: IBM POWER 6 p570, RAM 24GB, 2 CPUs 4704 MHz Software: AIX 6.1, OpenEdge 11.0, Oracle 11gR2 Database: ATM database = 7GB Tables# records Branches5,000 Tellers50,000 Accounts50,000,000
Database Size PUG Challenge Americas 2012 Performance Testing Progress and Oracle Progress DB/area size 7,442,137,088 Oracle DB/tablespace size7,688,953,856 Oracle db appear to be 3% more in bytes
Backup Size and Speed PUG Challenge Americas 2012 Performance Testing Progress and Oracle ProgressOracleOracle ( compressed ) time94 sec140 sec240 seconds size7GB7.8GB735MB
ASCII Dump (in seconds) PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgressOracle 10, , ,000, ,000, for each account where account.id < "condition“ no-lock: export account. select * from account where account.id < "condition"
ASCII Load (in seconds) PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgressOracle 100, ,000, ,000, repeat: create account. import account. insert into account select * from stg_account; -- External table
Binary Dump (in seconds) PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgress Oracle 50,000, proutil atm -C dump PUB.account /dir -index 0 –RO expdp user/passwd TABLES=ACCOUNT directory=DATA_DIR dumpfile=expdp.dmp parallel=2 -- Data Pump
Binary Load with integrity PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgress Oracle 50,000, proutil atm -C load account.bd -B TB 31 -TM 32 -T /tmp impdp user/passwd directory=DATA_DIR dumpfile=expdp.dmp -- Data Pump
Binary Load no integrity (-i) PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgress Oracle 50,000, proutil atm -C load account.bd -i -B TB 31 -TM 32 -T /tmp impdp user/passwd directory=DATA_DIR dumpfile=expdp.dmp -- Data Pump
Binary Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Empty RM Block Free RM Block Full RM Block HWM
Binary Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Empty RM Block Full RM Block Full RM Block HWM
Binary Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Empty Full RM Block Full RM Block Full RM Block HWM
Oracle Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Empty RM Block Full RM Block Full RM Block HWM
Oracle Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Full RM Block Full RM Block Full RM Block HWM
Oracle Load PUG Challenge Americas 2012 Performance Testing Progress and Oracle Full RM Block Full RM Block Full RM Block HWM
Build a brand new index PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgress Oracle 50,000, proutil atm -C idxbuild area "Account Index" -thread 1 -threadnum 2 -TF 80 -TB 64 -TM 32 -B 256 -T /tmp -SG 64 CREATE UNIQUE INDEX account_pk ON account (id);
Rebuild existing index PUG Challenge Americas 2012 Performance Testing Progress and Oracle # recordsProgress Oracle 50,000, proutil atm -C idxbuild area "Account Index" -thread 1 -threadnum 2 -TF 80 -TB 64 -TM 32 -B 256 -T /tmp -SG 64 ALTER INDEX account_pk REBUILD PARALLEL 2;
ATM Test PUG Challenge Americas 2012 Performance Testing Progress and Oracle
atm1.sql PUG Challenge Americas 2012 Performance Testing Progress and Oracle
CLTransTPSConcAvgRMinR50%R90%R95%RMaxRProg atm1.p atm1.p atm1.p atm1.p atm1.p atm1.p atm1.p atm1.p atm1.p Progress ATM Results All tests run for 300 seconds
PUG Challenge Americas 2012 Performance Testing Progress and Oracle CLTimeTransTPSConcAvgRProg atm1.sql atm1.sql atm1.sql atm1.sql atm1.sql atm1.sql atm1.sql atm1.sql atm1.sql Oracle ATM Results All tests run for 300 seconds
PUG Challenge Americas 2012 Performance Testing Progress and Oracle
IBM Power 7 Model p GHz CPUs x 4 SMTs RAM 124 GB SAN V7000 Big box Test
PUG Challenge Americas 2012 Performance Testing Progress and Oracle
Type: DBS and CCOnly DBS Any -pf file anywhereinit*ora In $ORACLE_HOME/dbs Promon R&D / 1 / 12 or _Startupselect * from V$PARAMETER Startup parameters
PUG Challenge Americas 2012 Performance Testing Progress and Oracle
OEM parameters
PUG Challenge Americas 2012 Performance Testing Progress and Oracle -dbdb_name -Bmemory_target -bibufslog_buffer -nprocesses -spinspin_count -Ldml_locks -Ma 1Dedicated connections -Ma 2 or moreShared connections -cp* (I18N)NLS* National Language Support Startup parameters
Cluster Environment PUG Challenge Americas 2012 Performance Testing Progress and Oracle Progress in a ClusterReal Application Cluster (RAC)
Server 1 Memory Apw, Biw, Aiw, Wdog Server 2Server 1 Memory DBWn, LGWR ARCn, SMON Server 2 Memory DBWn, LGWR ARCn, SMON Active - PassiveActive – Active DB PUG Challenge Americas 2012 Performance Testing Progress and Oracle Cluster db
Server 1 Server 2 Memory Apw, Biw, Aiw, Wdog Server 1Server 2 Memory DBWn, LGWR ARCn, SMON PUG Challenge Americas 2012 Performance Testing Progress and Oracle Cluster db 2
PUG Challenge Americas 2012 Performance Testing Progress and Oracle Questions Web pagewww.proora.com Otherwww.peg.com