Oracle Database 10g:
Administration Workshop I
StudentGuide
D17090GC10
Edition 1.0
March 2004
D39126
®
Copyright © 2004, Oracle. All rights reserved.
This documentation contains proprietary information of Oracle Corporation. It is
provided under a license agreement containing restrictions on use and disclosure and
is also protected by copyright law. Reverse engineering of the software is prohibited.
If this documentation is delivered to a U.S. Government Agency of the Department of
Defense, then it is delivered with Restricted Rights and the following legend is
applicable:
Restricted Rights Legend
Use, duplication or disclosure by the Government is subject to restrictions for
commercial computer software and shall be deemed to be Restricted Rights software
under Federal law, as set forth in subparagraph (c)(1)(ii) of DFARS 252.227-7013,
Rights in Technical Data and Computer Software (October 1988).
This material or any portion of it may not be copied in any formor by any means
without the express prior written permission of Oracle Corporation. Any other copying
is a violation of copyright law and may result in civil and/or criminal penalties.
If this documentation is delivered to a U.S. Government Agency not within the
Department of Defense, then it is delivered with “Restricted Rights,” as defined in
FAR 52.227-14, Rights in Data-General, including Alternate III (June 1987).
The information in this document is subject to change without notice. If you find any
problems in the documentation, please report them in writing to Education Products,
Oracle Corporation, 500 Oracle Parkway, Redwood Shores, CA 94065. Oracle
Corporation does not warrant that this document is error-free.
Oracle and all references to Oracle Products are trademarks or registered trademarks
of Oracle Corporation.
All other products or company names are used for identification purposes only, and
may be trademarks of their respective owners.
Authors
RicVan Dyke
Russ Lowenthal
Technical Contributors
and Reviewers
Donna Keesling
S. Matt Taylor
Jean-Francois Verrier
Craig Hollister
Bob Bungenstock
Tony Woodell
Joel Goodman
John Watson
Dairy Chan
Martin Jensen
Janet Stern
Dr. Sabine Teuber
Kyle Hailey
Christopher Lawless
Dominique Laugraud
Isabelle Marchand
Yi Lu
Editor
Elizabeth Treacy
Publisher
Jobi Varghese
1 Introduction
Objectives 1-2
Course Objectives 1-3
Oracle Products 1-4
Relational Database Systems 1-5
How the Data Is Organized 1-6
Integrity Constraints 1-7
Structured Query Language 1-8
Tasks of an Oracle Database Administrator 1-9
Summary 1-10
2 Installing Oracle Database 10g Software
Objectives 2-2
System Requirements 2-3
Optimal Flexible Architecture (OFA) 2-4
Using Optimal Flexible Architecture 2-5
Setting Environment Variables 2-7
PreinstallationChecks 2-9
Oracle Universal Installer 2-10
Inventory and UNIX Group Name 2-11
orainstRoot.sh 2-12
File Locations 2-14
Install Type 2-15
Prerequisite Checks 2-16
Starter Database 2-17
Configuration and Management 2-18
File Storage and Backup Recovery 2-19
Passwords and Summary 2-20
Installation 2-21
Configuration Assistants 2-22
Summary 2-24
Practice 2: Installing the Oracle Software 2-25
3 Creating an Oracle Database
Objectives 3-2
Database Architecture 3-3
Exploring the Storage Structure 3-4
Control Files 3-5
Redo Log Files 3-6
TablespacesandDatafiles 3-7
Segments, Extents, and Blocks 3-8
Contents
i
Oracle Instance Management 3-9
Oracle Memory Structures 3-10
Oracle Processes 3-12
Data Dictionary 3-13
Database Control 3-14
Grid Control 3-15
Database Configuration Assistant (DBCA) Overview 3-16
Creating a Database 3-17
Database Identification 3-18
Management Options 3-19
Passwords and Storage 3-20
File Locations and Backup Recovery 3-21
File Location Variables 3-22
Content and Initialization Parameters 3-23
Database Storage 3-25
Creation Options and Create 3-26
Other Actions with DBCA 3-27
Summary 3-28
Practice 3: Creating an Oracle Database 3-29
4 Database Interfaces
Objectives 4-2
What Is SQL? 4-3
Using SQL 4-4
Enterprise Manager: Seeing the SQL 4-5
What Is SQL*Plus? 4-6
What Is iSQL*Plus? 4-7
Using iSQL*Plus 4-9
Describing Data 4-10
Querying Data 4-11
Sorting the Data 4-12
Joining Tables 4-13
Manipulating Data 4-15
Defining Data 4-16
Overview of Transactions 4-17
Transaction Control Statements 4-18
Locking Data 4-19
Other Statement Categories 4-20
What Is PL/SQL? 4-21
Example PL/SQL Block 4-22
Uses of PL/SQL 4-23
What Is Java? 4-24
Oracle and Java 4-25
ii
What Is OCI? 4-26
Other APIs 4-27
Summary 4-29
Practice 4: Using SQL 4-30
5 Controlling the Database
Objectives 5-2
Starting and Stopping iSQL*Plus 5-3
Management Framework 5-4
Starting and Stopping Database Control 5-5
Accessing Database Control 5-6
SYSOPER and SYSDBA 5-7
Database Home Page 5-8
Changing the Listener Status 5-9
Startup and Shutdown 5-10
Starting Up a Database NOMOUNT 5-11
Starting Up a Database MOUNT 5-12
Starting Up a Database OPEN 5-13
Shutting Down the Database 5-14
SHUTDOWN Options 5-15
Initialization Parameter Files 5-18
Viewing Initialization Parameters 5-19
Viewing the Alert Log 5-20
Summary 5-21
Practice 5: Controlling the Database 5-22
6 Storage Structures
Objectives 6-2
Tablespacesand Data Files 6-3
Space Management inTablespaces 6-4
Creating a NewTablespace 6-5
Storage for Locally ManagedTablespaces 6-7
Tablespacesin thePreconfiguredDatabase 6-9
Altering aTablespace 6-11
Actions withTablespaces 6-13
DroppingTablespaces 6-15
ViewingTablespaceInformation 6-16
Summary 6-17
Practice 6: Working withTablespaces 6-18
iii