Oracle Certificate Professional Preparation

I passed my Oracle Database 10g Certified Associate (OCA) on the beginning of 2006. After busy on my work several months. I started to prepare my Oracle Database 10g Administrator Certified Professional (OCP) exam.

This is my OCP exam studying dairy. I hope can share something to anyone whom want to take the OCP exam.


Sunday, August 20, 2006

The RMAN repository must synchronize with the control file to generate accurate information.
In addition, the
CHANGE, UNCATALOG, and CROSSCHECK commands should have been recently executed
for the report.


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Saturday, August 19, 2006

Dynamic View to check National Language Support (NLS) parameters

V$NLS_VALID_VALUES

NLS_INSTANCE_PARAMETERS

NLS_DATABASE_PARAMETERS

NLS_SESSION_PARAMETERS


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

Major objects in the Oracle Scheduler








1. ProgramStore in USER tablespaceCan be ENABLE / DISABLE
2. ScheduleStore in USER tablespaceCANNOT be ENABLE / DISABLE
3. JobStore in USER tablespaceCan be ENABLE / DISABLE
4. Job ClassStore in SYS tablespace
5. WindowStore in SYS tablespace
6. Window GroupStore in SYS tablespace

Friday, August 18, 2006

Migrate non-ASM to ASM

1. Note the filenames of the control files and online redo log files
2. Shutdown the database using NORMAL, IMMEDIATE or TRANSACTIONAL keywords
3. Backup the database
4. Edit the SPFILE to use OMF for all file destinations
5. Edit the SPFILE to remove the CONTROL_FILE parameter
6. Run the following RMAN script:

RMAN> STARTUP NOMOUNT;
RMAN> RESTORE CONTROLFILE FROM controlfile_location
RMAN> ALTER DATABASE MOUNT;
RMAN> BACKUP AS COPY DATABASE FORMAT '+diskgroup_destination';
RMAN> SWITCH DATABASE TO COPY;
RMAN> SQL ALTER DATABASE RENAME logfile TO '+diskgroup_destination';
RMAN> ALTER DATABASE OPEN RESETLOGS;

7. Delete or archive the old dtaabase files;


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Sunday, August 13, 2006

Scheduler & Resource Manager Objects relationship in UML




NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Syntax of Incomplete Recovery command

SQL>REOVER DATABASE option

where option can be:
UNTIL TIME 'YYYY-MM-DD HH24:MI:SS'
UNTIL CHANGE
USING BACKUP CONTROLFILE





User Managed Recovery supported optionServer Managed Recovery supported option
UNITL TIME 'YYYY-MM-DD HH24:MI:SS'
UNIT CHANGEUNTIL SCN
UNIT CANCELUNITIL SEQUENCE



NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Saturday, August 12, 2006

Procedures in DBMS_REPAIR package

1. ADMIN_TABLES
2. CHECK_OBJECT
3. FIX_CORRUPT_BLOCKS
4. SKIP_CORRUPT_BLOCKS
5. REBUILD_FREELISTS
6. SEGMENT_FIX_STATUS
7. DUMP_ORPHANS_KEYS


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Wednesday, August 09, 2006

Change default backup device type

By default the RMAN backup device type is DISK.

Change the default device type for the RMAN automatic channel allocation:
RMAN> CONFIGURE DEFAULT BACKUP DEVICE TYPE STB;

Change the default device type for the RMAN manual channel allocation:
RMAN> RUN {
2> ALLOCATE CHANNEL c1 DEVICE TYPE DISK;
3> BACKUP ... ;
4> }



NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process
MML- Media Management Layer

Compare 2 commands uses in backup flash recovery area














RMAN> BACKUP RECOVERY AREA RMAN> BACKUP RECOVERY FILES
Backup all flash recovery files created in flash recovery area destination Backup all flash recovery files on disk
- Control file autobackup

- full and incremental backup sets

- data file copies

- archive logs


- Control file autobackup

- full and incremental backup sets

- data file copies

- archive logs

- flashback logs

- incremental bitmaps

- current control file

- online redo log files



NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Sunday, August 06, 2006

Reasons to performs Incomplete Recovery

1. The Complete Recovery is failed
2. Need to use the backup confrol file to open the database
3. The current redo log or the data file is missing or lost


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

RMAN Report

RMAN> REPORT SCHEMA

RMAN> REPORT NEED BACKUP ...

RMAN> REPORT UNRECOVERABLE;

RMAN> REPORT OBSOLETE;


NOTES:
SBT - System Backup Tape
CTWR - Change Tracking Writer
RVWR - Recover Log Writer
RMAN - Recovery Manager
ASM - Automatic Storage Management
ADDM - Automatic Database Diagnostic Management
MML - Memony Monitoring Light process
MON - Memony Managaibility Monitoring process

MML- Media Management Layer

Tuesday, August 01, 2006

RMAN Retention Policy

2 types of retention policy

1. Recovery Window
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS

SYSDATE - checkpoint_time <= RECOVERY WINDOW

This means, it is possible to discover logical error and fix affected object by point-in-time reovery to just before the error occurs

2. Redundancy
Always has the number of redundacy of data file backup. A backup can deemed when the more recently backup of the data file has been backup.