Documente Academic
Documente Profesional
Documente Cultură
Backup Types
Logical Cold
Hot
Physical
With Without
Issues
Protect the database from numerous types of failures Increase Mean-Time-Between-Failures (MTBF) Decrease Mean-Time-To-Recover (MTTR) Minimize data loss
Categories of Failures
Statement failure
No Recovery Needed
Logic error in an application Attempt to enter bad data into the table Attempt an operation with insufficient privileges Attempt an INSERT or UPDATE to a table, causing an extent to be allocated, but with insufficient free space left in the tablespace
Categories of Failures
Statement failure User process failure
No Recovery Needed PMON
The user performed an abnormal disconnect in the session. The users session was abnormally terminated. The users program raised an address exception terminating the session.
Categories of Failures
Statement failure User process failure User error
Recovery Needed IMP Utility
Categories of Failures
Statement failure User process failure User error Instance failure
No Recovery Needed PMON SMON
Categories of Failures
Statement failure User process failure User error Instance failure Media failure
Recovery Needed Physical
Technical requirements
Hardware, software, man power and time Database configurations Transaction volume Frequency of backups
Operational requirements
7-day / 24-hour operations Testing and validating backups
No archive mode
ARCHIVELOG
Online redo log files
Group 1 Group 2
053
053
052
LOG_ARCHIVE_DEST LOG_ARCHIVE_FORMAT
Init.ora
Control file
SHUTDOWN IMMEDIATE;
Data files
Control files
STARTUP OPEN;
Control files
Parameter files
Pwd file
Physical Opened Database All tablespace data Backup (2) Individual data
files file
SQL> alter tablespace <name> begin backup;
Data files
HOST cp <files> /backup/
SQL> alter tablespace <name> end backup;
ARC0
Redo log files
Data files
Control file
1 2
ARC0
Data files
Control file
3 2
ARC0
Data files
Control file
3 4
ARC0
Data files
Control file
5 4
ARC0
Data files
Control file
5 5
Data files
Control file
5 6
ARC0
Data files
3
5
Control file
5 5
Data files
Control file
9 8
ARC0
Data files
3
5
4
6 8
Control file
5 5
Data files
Control file
1
2 3
9 9 5 9
Shutdown
Startup Mount
O.S. Restore From Hot or Cold Physical BackUp DataFile (s)
9 8
4a 4b 5
Data files
9
Alter DataBase Open Shutdown Immediate New Cold Physical BackUp Startup Open
Control file
6 7 8
Control file
RedoRecord
Log file #
Log file Low SCN # Higth SCN #
Data Base
Exp
File *.dmp
Data Base
Imp
Export Concepts
Oracle Server
Generate SQL commands Two-Task common (TTC) SQL command processing Buffer cache manager Analyze blocks
Dump file
TTC buffer
Evaluating buffer
Buffer cache
Read blocks
1
1a
Full
Owner
Tables
Oracle9i Server
1c
IncType Incremental
KEYWORD DESCRIPTION (DEFAULT) ----------------------------------------------------------------USERID username/password BUFFER size of data buffer FILE LOG PARFILE FILESIZE COMPRESS CONSISTENT GRANTS INDEXES ROWS CONSTRAINTS TRIGGERS FULL OWNER TABLES INCTYPE DIRECT STATISTICS output files (EXPDAT.DMP) log file of screen output parameter filename maximum size of each dump file import into one extent cross-table consistency export export export export export grants indexes data rows constraints triggers (Y) (N) (Y) (Y) (Y) (Y) (Y) (N)
export entire DataBase list of owner usernames list of table names incremental export type direct path analyze objects
(N) (ESTIMATE)
Command-Line Method > exp scott/tiger file=scott.dmp owner=scott grants=Y rows=Y compress=Y Export Messages Export: Release 9.2.0.4.0 - Production on Fri Oct 30 09:35:33 1998 (c) Copyright 2003 Oracle Corporation. All rights reserved. Connected to: Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production With the Partitioning option PL/SQL Release 9.2.0.4.0 - Production Export done in WE8DEC character set and WE8DEC NCHAR character set . exporting pre-schema procedural objects and actions . exporting foreign function library names for user SCOTT . exporting object type definitions for user SCOTT About to export SCOTTs objects ... . exporting database links . exporting sequence numbers . exporting cluster definitions . about to export SCOTTs tables via Conventional Path ... . . exporting table BONUS 0 rows exported . . exporting table DEPT 4 rows exported . . exporting table EMP 14 rows exported
IncType Complete IncType Incremental -----> Exp IncType Generic IncType Cumulative -----> Exp IncType Cumulative or Complete
DBWR
Primary DB
Standby DB
Recovery Mode
Activate
ReadOnly Mode