SlideShare a Scribd company logo
1 of 25
Oracle Architecture 1
Cost: Enterprise Edition US$47,500.00 / Processor 2
Agenda What is Oracle instance Database Listener Cost Base Optimizer 3
4 The more you understand The less you need to memorize more Memorize less Shallow In-depth Understanding
5
Before startup Connected to an idle instance. sys@CS11GR2> !ps -ef | grepcs11gR2 | grep -v grep sys@CS11GR2> !ipcs -m ------ Shared Memory Segments -------- key        shmid      owner      perms      bytes      nattch     status 6
instance startup sys@CS11GR2> startup nomount ORACLE instance started. Total System Global Area  535662592 bytes Fixed Size                  1337720 bytes Variable Size             322963080 bytes Database Buffers          205520896 bytes Redo Buffers                5840896 bytes 7
After instance is started sys@CS11GR2> !ipcs -m ------ Shared Memory Segments -------- key        shmid      owner      perms      bytes      nattch     status 0x44c4474c 360449     oracle     660        538968064  16 8
9 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
After instance is started sys@CS11GR2> !ps -ef | grepcs11gR2| grep -v grep oracle   13134     1  0 13:54 ?        00:00:00 ora_dbw0_cs11gR2 oracle   13136     1  0 13:54 ?        00:00:00 ora_lgwr_cs11gR2 		. 		. 		. oracle   13116     1  0 13:54 ?        00:00:00 ora_pmon_cs11gR2  oracle   13140     1  0 13:54 ?        00:00:00 ora_smon_cs11gR2 SQL> !ps -ef | grep cs11gR2 | grep -v grep | wc -l 16 10
11 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
Open the Database sys@CS11GR2> alter database mount; Database altered. sys@CS11GR2> alter database open; Database altered. sys@CS11GR2> select * from sid.emp where ename='SMITH'; EMPNO  ENAME      JOB          MGR HIREDATE    SAL   COMM   DEPTNO ------ ---------- --------- ------ --------- ----- ------ --------   7369 SMITH      CLERK       7902 17-DEC-80   800              20 1 row selected. 12
13 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
Connect from RemoteFailed! C:ocuments and Settingshensi4>sqlplussid/sid@cs11g SQL*Plus: Release 10.2.0.1.0 - Production on Sun Jul 24 20:29:17 2011 Copyright (c) 1982, 2005, Oracle.  All rights reserved. ERROR: ORA-12541: TNS:no listener 14
Startup the Listener oracle@cargosmart:~/scripts$ lsnrctl start Service "cs11gR2" has 1 instance(s).   Instance "cs11gR2", status READY, has 1 handler(s) for this service... The command completed successfully 15
Now query from Remote C:ocuments and Settingshensi4>sqlplussid/sid@cs11gR2 Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select * from emp where ename='SMITH';   EMPNO ENAME   JOB       MGR HIREDATE    SAL   COMM   DEPTNO ------- ------- ------- ----- --------- ----- ------ --------    7369 SMITH   CLERK    7902 17-DEC-80   800              20 1 row selected. 16
17 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
What Oracle Do When you submit a SQL From pl/sql develop From the JDBC API in your java        application From sqlplus 18
19 SELECT AVG(SAL)  FROM EMP  WHERE DEPTNO IN    (SELECT DEPTNO     FROM DEPT    WHERE DNAME='SALES') Parser
20 SELECT AVG(SAL)  FROM EMP  WHERE DEPTNO IN    (SELECT DEPTNO     FROM DEPT    WHERE DNAME='SALES') Parser
21 SELECT AVG(SAL)  FROM DEPT, EMP  WHERE EMP.DEPTNO=DEPT.DEPTNO AND DEPT.DNAME='SALES'; Query Transformer Transformed Query Statistics Estimator Data Dictionary Query + Cost Plan Generator
22 Query Transformer Transformed Query Statistics Estimator Data Dictionary Query + Cost Plan Generator
23 Query  Plan Row Source Generator SQL Execution Result
A Real Plan ---------------------------------------------------------------------- | Id  | Operation                     | Name    | Rows  | Cost (%CPU)| ---------------------------------------------------------------------- |   0 | SELECT STATEMENT              |         |     1 |     6  (17)| |   1 |  SORT AGGREGATE               |         |     1 |            | |   2 |   MERGE JOIN                  |         |     5 |     6  (17)| |*  3 |    TABLE ACCESS BY INDEX ROWID| DEPT    |     1 |     2   (0)| |   4 |     INDEX FULL SCAN           | DEPT_PK |     4 |     1   (0)| |*  5 |    SORT JOIN                  |         |    14 |     4  (25)| |   6 |     TABLE ACCESS FULL         | EMP     |    14 |     3   (0)| ---------------------------------------------------------------------- Predicate Information (identified by operation id): ---------------------------------------------------    3 - filter("DNAME"='SALES')    5 - access("DEPTNO"="DEPTNO")        filter("DEPTNO"="DEPTNO") 24
Q & A 25

More Related Content

What's hot

Oracle 12c Multi Tenant
Oracle 12c Multi TenantOracle 12c Multi Tenant
Oracle 12c Multi TenantRed Stack Tech
 
Oracle architecture
Oracle architectureOracle architecture
Oracle architectureSoumya Das
 
Oracle10g New Features I
Oracle10g New Features IOracle10g New Features I
Oracle10g New Features IDenish Patel
 
What’s new in oracle 12c recovery manager (rman)
What’s new in oracle 12c recovery manager (rman)What’s new in oracle 12c recovery manager (rman)
What’s new in oracle 12c recovery manager (rman)Satishbabu Gunukula
 
Install oracle binaris or clonse oracle home
Install oracle binaris or clonse oracle homeInstall oracle binaris or clonse oracle home
Install oracle binaris or clonse oracle homeSatishbabu Gunukula
 
DBA 101 : Calling all New Database Administrators (WP)
DBA 101 : Calling all New Database Administrators (WP)DBA 101 : Calling all New Database Administrators (WP)
DBA 101 : Calling all New Database Administrators (WP)Gustavo Rene Antunez
 
Oracle data guard configuration in 12c
Oracle data guard configuration in 12cOracle data guard configuration in 12c
Oracle data guard configuration in 12cuzzal basak
 
Backup and Recovery Procedure
Backup and Recovery ProcedureBackup and Recovery Procedure
Backup and Recovery ProcedureAnar Godjaev
 
Oracle RDBMS architecture
Oracle RDBMS architectureOracle RDBMS architecture
Oracle RDBMS architectureMartin Berger
 
Backup and Restore of database on 2-Node RAC
Backup and Restore of database on 2-Node RACBackup and Restore of database on 2-Node RAC
Backup and Restore of database on 2-Node RACPaulo Fagundes
 
Oracle 12c PDB insights
Oracle 12c PDB insightsOracle 12c PDB insights
Oracle 12c PDB insightsKirill Loifman
 
Oracle Database Management Basic 1
Oracle Database Management Basic 1Oracle Database Management Basic 1
Oracle Database Management Basic 1Chien Chung Shen
 
Oracle Database 12c "New features"
Oracle Database 12c "New features" Oracle Database 12c "New features"
Oracle Database 12c "New features" Anar Godjaev
 
Oracle database 12c introduction- Satyendra Pasalapudi
Oracle database 12c introduction- Satyendra PasalapudiOracle database 12c introduction- Satyendra Pasalapudi
Oracle database 12c introduction- Satyendra Pasalapudipasalapudi123
 
RMAN in 12c: The Next Generation (PPT)
RMAN in 12c: The Next Generation (PPT)RMAN in 12c: The Next Generation (PPT)
RMAN in 12c: The Next Generation (PPT)Gustavo Rene Antunez
 

What's hot (20)

Oracle 12c Multi Tenant
Oracle 12c Multi TenantOracle 12c Multi Tenant
Oracle 12c Multi Tenant
 
Oracle architecture
Oracle architectureOracle architecture
Oracle architecture
 
DBA oracle
DBA oracleDBA oracle
DBA oracle
 
RMAN – The Pocket Knife of a DBA
RMAN – The Pocket Knife of a DBA RMAN – The Pocket Knife of a DBA
RMAN – The Pocket Knife of a DBA
 
Oracle10g New Features I
Oracle10g New Features IOracle10g New Features I
Oracle10g New Features I
 
What’s new in oracle 12c recovery manager (rman)
What’s new in oracle 12c recovery manager (rman)What’s new in oracle 12c recovery manager (rman)
What’s new in oracle 12c recovery manager (rman)
 
Install oracle binaris or clonse oracle home
Install oracle binaris or clonse oracle homeInstall oracle binaris or clonse oracle home
Install oracle binaris or clonse oracle home
 
Oracle 12c Architecture
Oracle 12c ArchitectureOracle 12c Architecture
Oracle 12c Architecture
 
DBA 101 : Calling all New Database Administrators (WP)
DBA 101 : Calling all New Database Administrators (WP)DBA 101 : Calling all New Database Administrators (WP)
DBA 101 : Calling all New Database Administrators (WP)
 
Oracle data guard configuration in 12c
Oracle data guard configuration in 12cOracle data guard configuration in 12c
Oracle data guard configuration in 12c
 
Backup and Recovery Procedure
Backup and Recovery ProcedureBackup and Recovery Procedure
Backup and Recovery Procedure
 
Oracle RDBMS architecture
Oracle RDBMS architectureOracle RDBMS architecture
Oracle RDBMS architecture
 
Backup and Restore of database on 2-Node RAC
Backup and Restore of database on 2-Node RACBackup and Restore of database on 2-Node RAC
Backup and Restore of database on 2-Node RAC
 
Oracle 12c PDB insights
Oracle 12c PDB insightsOracle 12c PDB insights
Oracle 12c PDB insights
 
Oracle Database Management Basic 1
Oracle Database Management Basic 1Oracle Database Management Basic 1
Oracle Database Management Basic 1
 
Oracle Database 12c "New features"
Oracle Database 12c "New features" Oracle Database 12c "New features"
Oracle Database 12c "New features"
 
Oracle database 12c introduction- Satyendra Pasalapudi
Oracle database 12c introduction- Satyendra PasalapudiOracle database 12c introduction- Satyendra Pasalapudi
Oracle database 12c introduction- Satyendra Pasalapudi
 
Convert single instance to RAC
Convert single instance to RACConvert single instance to RAC
Convert single instance to RAC
 
Less01 Dba1
Less01 Dba1Less01 Dba1
Less01 Dba1
 
RMAN in 12c: The Next Generation (PPT)
RMAN in 12c: The Next Generation (PPT)RMAN in 12c: The Next Generation (PPT)
RMAN in 12c: The Next Generation (PPT)
 

Viewers also liked

Oracle Database Overview
Oracle Database OverviewOracle Database Overview
Oracle Database Overviewhonglee71
 
Oracle Architecture
Oracle ArchitectureOracle Architecture
Oracle ArchitectureNeeraj Singh
 
Oracle architecture ppt
Oracle architecture pptOracle architecture ppt
Oracle architecture pptDeepak Shetty
 
Présentation Oracle DataBase 11g
Présentation Oracle DataBase 11gPrésentation Oracle DataBase 11g
Présentation Oracle DataBase 11gCynapsys It Hotspot
 
Oracle Database Architecture - EN
Oracle Database Architecture - ENOracle Database Architecture - EN
Oracle Database Architecture - ENMichal Simonik
 
Oracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsOracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsYogiji Creations
 
A History of Oracle Corporation
A History of Oracle CorporationA History of Oracle Corporation
A History of Oracle Corporationdsp
 
Oracle Business Strategy
Oracle Business StrategyOracle Business Strategy
Oracle Business Strategysathyagenius
 
ORACLE PL SQL FOR BEGINNERS
ORACLE PL SQL FOR BEGINNERSORACLE PL SQL FOR BEGINNERS
ORACLE PL SQL FOR BEGINNERSmohdoracle
 
Best Practices - PHP and the Oracle Database
Best Practices - PHP and the Oracle DatabaseBest Practices - PHP and the Oracle Database
Best Practices - PHP and the Oracle DatabaseChristopher Jones
 
DBA Commands and Concepts That Every Developer Should Know
DBA Commands and Concepts That Every Developer Should KnowDBA Commands and Concepts That Every Developer Should Know
DBA Commands and Concepts That Every Developer Should KnowAlex Zaballa
 
Backup & recovery with rman
Backup & recovery with rmanBackup & recovery with rman
Backup & recovery with rmanitsabidhussain
 
Oracle sql tutorial
Oracle sql tutorialOracle sql tutorial
Oracle sql tutorialMohd Tousif
 
Introduction to Oracle Database
Introduction to Oracle DatabaseIntroduction to Oracle Database
Introduction to Oracle Databasepuja_dhar
 
Oracle database 12c new features
Oracle database 12c new featuresOracle database 12c new features
Oracle database 12c new featuresJakkrapat S.
 
Rdbms
RdbmsRdbms
Rdbmsrdbms
 
A must Sql notes for beginners
A must Sql notes for beginnersA must Sql notes for beginners
A must Sql notes for beginnersRam Sagar Mourya
 
White Paper - What is new at 11g for Backup and Recovery
White Paper - What is new at 11g for Backup and RecoveryWhite Paper - What is new at 11g for Backup and Recovery
White Paper - What is new at 11g for Backup and RecoveryFrancisco Alvarez
 

Viewers also liked (20)

Oracle Database Overview
Oracle Database OverviewOracle Database Overview
Oracle Database Overview
 
Oracle Architecture
Oracle ArchitectureOracle Architecture
Oracle Architecture
 
Oracle architecture ppt
Oracle architecture pptOracle architecture ppt
Oracle architecture ppt
 
Présentation Oracle DataBase 11g
Présentation Oracle DataBase 11gPrésentation Oracle DataBase 11g
Présentation Oracle DataBase 11g
 
Oracle Database Architecture - EN
Oracle Database Architecture - ENOracle Database Architecture - EN
Oracle Database Architecture - EN
 
Oracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creationsOracle architecture with details-yogiji creations
Oracle architecture with details-yogiji creations
 
A History of Oracle Corporation
A History of Oracle CorporationA History of Oracle Corporation
A History of Oracle Corporation
 
Oracle Business Strategy
Oracle Business StrategyOracle Business Strategy
Oracle Business Strategy
 
ORACLE PL SQL FOR BEGINNERS
ORACLE PL SQL FOR BEGINNERSORACLE PL SQL FOR BEGINNERS
ORACLE PL SQL FOR BEGINNERS
 
Best Practices - PHP and the Oracle Database
Best Practices - PHP and the Oracle DatabaseBest Practices - PHP and the Oracle Database
Best Practices - PHP and the Oracle Database
 
Relational Database Management System
Relational Database Management SystemRelational Database Management System
Relational Database Management System
 
DBA Commands and Concepts That Every Developer Should Know
DBA Commands and Concepts That Every Developer Should KnowDBA Commands and Concepts That Every Developer Should Know
DBA Commands and Concepts That Every Developer Should Know
 
Backup & recovery with rman
Backup & recovery with rmanBackup & recovery with rman
Backup & recovery with rman
 
Oracle sql tutorial
Oracle sql tutorialOracle sql tutorial
Oracle sql tutorial
 
Introduction to Oracle Database
Introduction to Oracle DatabaseIntroduction to Oracle Database
Introduction to Oracle Database
 
Best sql plsql material
Best sql plsql materialBest sql plsql material
Best sql plsql material
 
Oracle database 12c new features
Oracle database 12c new featuresOracle database 12c new features
Oracle database 12c new features
 
Rdbms
RdbmsRdbms
Rdbms
 
A must Sql notes for beginners
A must Sql notes for beginnersA must Sql notes for beginners
A must Sql notes for beginners
 
White Paper - What is new at 11g for Backup and Recovery
White Paper - What is new at 11g for Backup and RecoveryWhite Paper - What is new at 11g for Backup and Recovery
White Paper - What is new at 11g for Backup and Recovery
 

Similar to Oracle Basics and Architecture

11 Things About11g
11 Things About11g11 Things About11g
11 Things About11gfcamachob
 
11thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp0111thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp01Karam Abuataya
 
Thomas+Niewel+ +Oracletuning
Thomas+Niewel+ +OracletuningThomas+Niewel+ +Oracletuning
Thomas+Niewel+ +Oracletuningafa reg
 
Troubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTroubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTanel Poder
 
IO_Analysis_with_SAR.ppt
IO_Analysis_with_SAR.pptIO_Analysis_with_SAR.ppt
IO_Analysis_with_SAR.pptcookie1969
 
Oracle RAC Presentation at Oracle Open World
Oracle RAC Presentation at Oracle Open WorldOracle RAC Presentation at Oracle Open World
Oracle RAC Presentation at Oracle Open WorldPaul Marden
 
Debugging Ruby
Debugging RubyDebugging Ruby
Debugging RubyAman Gupta
 
Top 10 tips for Oracle performance
Top 10 tips for Oracle performanceTop 10 tips for Oracle performance
Top 10 tips for Oracle performanceGuy Harrison
 
In Memory Database In Action by Tanel Poder and Kerry Osborne
In Memory Database In Action by Tanel Poder and Kerry OsborneIn Memory Database In Action by Tanel Poder and Kerry Osborne
In Memory Database In Action by Tanel Poder and Kerry OsborneEnkitec
 
Oracle Database In-Memory Option in Action
Oracle Database In-Memory Option in ActionOracle Database In-Memory Option in Action
Oracle Database In-Memory Option in ActionTanel Poder
 
Your tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and AdvisorsYour tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and AdvisorsJohn Kanagaraj
 
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...Compuware
 
Percona Live UK 2014 Part III
Percona Live UK 2014  Part IIIPercona Live UK 2014  Part III
Percona Live UK 2014 Part IIIAlkin Tezuysal
 
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New FeaturesAmazon Web Services
 
pg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLpg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLCommand Prompt., Inc
 
pg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLpg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLMark Wong
 
z/VM Performance Analysis
z/VM Performance Analysisz/VM Performance Analysis
z/VM Performance AnalysisRodrigo Campos
 
Linux Systems Performance 2016
Linux Systems Performance 2016Linux Systems Performance 2016
Linux Systems Performance 2016Brendan Gregg
 

Similar to Oracle Basics and Architecture (20)

11 Things About11g
11 Things About11g11 Things About11g
11 Things About11g
 
11thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp0111thingsabout11g 12659705398222 Phpapp01
11thingsabout11g 12659705398222 Phpapp01
 
Thomas+Niewel+ +Oracletuning
Thomas+Niewel+ +OracletuningThomas+Niewel+ +Oracletuning
Thomas+Niewel+ +Oracletuning
 
Troubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contentionTroubleshooting Complex Performance issues - Oracle SEG$ contention
Troubleshooting Complex Performance issues - Oracle SEG$ contention
 
IO_Analysis_with_SAR.ppt
IO_Analysis_with_SAR.pptIO_Analysis_with_SAR.ppt
IO_Analysis_with_SAR.ppt
 
Oracle RAC Presentation at Oracle Open World
Oracle RAC Presentation at Oracle Open WorldOracle RAC Presentation at Oracle Open World
Oracle RAC Presentation at Oracle Open World
 
PoC Oracle Exadata - Retour d'expérience
PoC Oracle Exadata - Retour d'expériencePoC Oracle Exadata - Retour d'expérience
PoC Oracle Exadata - Retour d'expérience
 
Debugging Ruby
Debugging RubyDebugging Ruby
Debugging Ruby
 
Top 10 tips for Oracle performance
Top 10 tips for Oracle performanceTop 10 tips for Oracle performance
Top 10 tips for Oracle performance
 
Rmoug ashmaster
Rmoug ashmasterRmoug ashmaster
Rmoug ashmaster
 
In Memory Database In Action by Tanel Poder and Kerry Osborne
In Memory Database In Action by Tanel Poder and Kerry OsborneIn Memory Database In Action by Tanel Poder and Kerry Osborne
In Memory Database In Action by Tanel Poder and Kerry Osborne
 
Oracle Database In-Memory Option in Action
Oracle Database In-Memory Option in ActionOracle Database In-Memory Option in Action
Oracle Database In-Memory Option in Action
 
Your tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and AdvisorsYour tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
Your tuning arsenal: AWR, ADDM, ASH, Metrics and Advisors
 
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...
Using Compuware Strobe to Save CPU: 4 Real-life Cases from the Files of CPT G...
 
Percona Live UK 2014 Part III
Percona Live UK 2014  Part IIIPercona Live UK 2014  Part III
Percona Live UK 2014 Part III
 
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
 
pg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLpg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQL
 
pg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQLpg_proctab: Accessing System Stats in PostgreSQL
pg_proctab: Accessing System Stats in PostgreSQL
 
z/VM Performance Analysis
z/VM Performance Analysisz/VM Performance Analysis
z/VM Performance Analysis
 
Linux Systems Performance 2016
Linux Systems Performance 2016Linux Systems Performance 2016
Linux Systems Performance 2016
 

Recently uploaded

Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 

Recently uploaded (20)

Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 

Oracle Basics and Architecture

  • 2. Cost: Enterprise Edition US$47,500.00 / Processor 2
  • 3. Agenda What is Oracle instance Database Listener Cost Base Optimizer 3
  • 4. 4 The more you understand The less you need to memorize more Memorize less Shallow In-depth Understanding
  • 5. 5
  • 6. Before startup Connected to an idle instance. sys@CS11GR2> !ps -ef | grepcs11gR2 | grep -v grep sys@CS11GR2> !ipcs -m ------ Shared Memory Segments -------- key shmid owner perms bytes nattch status 6
  • 7. instance startup sys@CS11GR2> startup nomount ORACLE instance started. Total System Global Area 535662592 bytes Fixed Size 1337720 bytes Variable Size 322963080 bytes Database Buffers 205520896 bytes Redo Buffers 5840896 bytes 7
  • 8. After instance is started sys@CS11GR2> !ipcs -m ------ Shared Memory Segments -------- key shmid owner perms bytes nattch status 0x44c4474c 360449 oracle 660 538968064 16 8
  • 9. 9 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
  • 10. After instance is started sys@CS11GR2> !ps -ef | grepcs11gR2| grep -v grep oracle 13134 1 0 13:54 ? 00:00:00 ora_dbw0_cs11gR2 oracle 13136 1 0 13:54 ? 00:00:00 ora_lgwr_cs11gR2 . . . oracle 13116 1 0 13:54 ? 00:00:00 ora_pmon_cs11gR2 oracle 13140 1 0 13:54 ? 00:00:00 ora_smon_cs11gR2 SQL> !ps -ef | grep cs11gR2 | grep -v grep | wc -l 16 10
  • 11. 11 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
  • 12. Open the Database sys@CS11GR2> alter database mount; Database altered. sys@CS11GR2> alter database open; Database altered. sys@CS11GR2> select * from sid.emp where ename='SMITH'; EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO ------ ---------- --------- ------ --------- ----- ------ -------- 7369 SMITH CLERK 7902 17-DEC-80 800 20 1 row selected. 12
  • 13. 13 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
  • 14. Connect from RemoteFailed! C:ocuments and Settingshensi4>sqlplussid/sid@cs11g SQL*Plus: Release 10.2.0.1.0 - Production on Sun Jul 24 20:29:17 2011 Copyright (c) 1982, 2005, Oracle. All rights reserved. ERROR: ORA-12541: TNS:no listener 14
  • 15. Startup the Listener oracle@cargosmart:~/scripts$ lsnrctl start Service "cs11gR2" has 1 instance(s). Instance "cs11gR2", status READY, has 1 handler(s) for this service... The command completed successfully 15
  • 16. Now query from Remote C:ocuments and Settingshensi4>sqlplussid/sid@cs11gR2 Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select * from emp where ename='SMITH'; EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO ------- ------- ------- ----- --------- ----- ------ -------- 7369 SMITH CLERK 7902 17-DEC-80 800 20 1 row selected. 16
  • 17. 17 Instance System Global Area Shared Pool Server Processes Database Buffer Cache Library Cache Redo Log Buffer Data Dictionary Cache Listener Oracle Background Processes System Monitor (SMON) Database Writer (DBW0) Process Monitor (PMON) Check Point (CKPT) Log Writer (LGWR) Archiver (ARC0) Client Processes DataBase Data Files Control Files Redo Log Files
  • 18. What Oracle Do When you submit a SQL From pl/sql develop From the JDBC API in your java application From sqlplus 18
  • 19. 19 SELECT AVG(SAL) FROM EMP WHERE DEPTNO IN (SELECT DEPTNO FROM DEPT WHERE DNAME='SALES') Parser
  • 20. 20 SELECT AVG(SAL) FROM EMP WHERE DEPTNO IN (SELECT DEPTNO FROM DEPT WHERE DNAME='SALES') Parser
  • 21. 21 SELECT AVG(SAL) FROM DEPT, EMP WHERE EMP.DEPTNO=DEPT.DEPTNO AND DEPT.DNAME='SALES'; Query Transformer Transformed Query Statistics Estimator Data Dictionary Query + Cost Plan Generator
  • 22. 22 Query Transformer Transformed Query Statistics Estimator Data Dictionary Query + Cost Plan Generator
  • 23. 23 Query Plan Row Source Generator SQL Execution Result
  • 24. A Real Plan ---------------------------------------------------------------------- | Id | Operation | Name | Rows | Cost (%CPU)| ---------------------------------------------------------------------- | 0 | SELECT STATEMENT | | 1 | 6 (17)| | 1 | SORT AGGREGATE | | 1 | | | 2 | MERGE JOIN | | 5 | 6 (17)| |* 3 | TABLE ACCESS BY INDEX ROWID| DEPT | 1 | 2 (0)| | 4 | INDEX FULL SCAN | DEPT_PK | 4 | 1 (0)| |* 5 | SORT JOIN | | 14 | 4 (25)| | 6 | TABLE ACCESS FULL | EMP | 14 | 3 (0)| ---------------------------------------------------------------------- Predicate Information (identified by operation id): --------------------------------------------------- 3 - filter("DNAME"='SALES') 5 - access("DEPTNO"="DEPTNO") filter("DEPTNO"="DEPTNO") 24
  • 25. Q & A 25

Editor's Notes

  1. From Shop.oracle.comUS$47,500.00 / Processor for Enterprise EditionUS$23,000.00 / Processor for RACUS$11,500.00 / Processor for Partition