Just Clone Database – CREATE CONTROLFILE SET DATABASE


Just some idea, But It’s great for cloned database. You can read on Super fast Database Copying/Cloning Oracle Tips by Burleson Consulting.
This is idea for using CREATE CONTROLFILE SET DATABASE “NEW_DATABASE_NAME” RESETLOGS
Why I use it? because I use Oracle 9i (Don’t ask, why don’t I upgrade?) and No Archive Mode.

First step this , create controlfile to trace.

SQL> alter database backup controlfile to trace as ‘/tmp/ctrl.trc’;

Check in ‘/tmp/ctrl.trc’ file.

CREATE CONTROLFILE REUSE DATABASE “ORCL” NORESETLOGS NOARCHIVELOG
MAXLOGFILES 255
MAXLOGMEMBERS 2
MAXDATAFILES 256
MAXINSTANCES 1
MAXLOGHISTORY 1134
LOGFILE
GROUP 1 ‘/oradata/ORCL/redo11.log’ SIZE 20M,
GROUP 2 ‘/oradata/ORCL/redo21.log’ SIZE 20M
DATAFILE
‘/oradata/ORCL/system.dbf’,
‘/oradata/ORCL/undo.dbf’,
‘/oradata/ORCL/data01.dbf’,
‘/oradata/ORCL/index01.dbf’
CHARACTER SET US7ASCII
;

Continue reading

Advertisements

Oracle GoldenGate Initial Loading: Oracle Database to Oracle Database


For Oracle DB to Oracle DB initial loading, you can use the following approaches:

  • Import/Export with the flashback_scn option and start replication with aftercsn
  • Backup with RMAN and start replciat with atcsn
Different Between SCN and CSN
SCN is used in Oracle Database means SCN (System Change/Commit Number). CSN is used by Oracle GoldenGate means CSN (Checkpoint Sequence Number). They both refer to the same number for Oracle database transactions.

​1. Import/Export with flashback and start replication with AFTERCSN. 
The steps are as follows:​
Step 1. Start the Extract
GGSCI>start extract exext, begin now
Step 2. Check the Current SCN
SQL> select dbms_flashback.get_system_change_number() from dual; (for schema export) 
SQL> select current_scn from v$database ; (for database export)

Continue reading

Oracle GoldenGate Best Practices: Oracle Migrations and Upgrades 9i and up


Introduction

Eliminating database downtime poses a significant challenge for IT organizations that need to upgrade or migrate mission-critical database environments running Oracle Database 9i or Oracle Database 10g to Oracle Database 11g. This is particularly true for applications that must provide continuous or near-continuous operations to users who increasingly expect uninterrupted availability of online services. Any outage of an application or website, even if that outage is scheduled or planned, has an impact on the revenue and reputation of the business.

For databases that host the data for these mission-critical applications, availability requirements have become stringent. Unfortunately, there are essential events that require application downtime, including modifying hardware or database software, upgrading applications, applying software patches, and migrating to different computing architectures. Because such events are not considered a system or data failure, they are aptly classified as planned outages.

This document explains how organizations can upgrade or migrate from Oracle Database 9i or Oracle Database 10g to Oracle Database 11g with minimum downtime. Using Oracle GoldenGate’s real-time data integration and replication capabilities, businesses can create a clone database to offload instantiation and conversions, keep transactions in sync across the databases, manage partial or phased migrations and upgrades, conduct post upgrade/ migration data verification and implement a reliable failback strategy.

Continue reading

Issue installing the 11gR2 database software after the 12.1.0.2 clusterware setup


If you don’t plan to install the 11gR2 database software after a 12.1.0.2 clusterware installation, I guess there is no need for you to read this post.

I just want to share the issue I got and the way you could workaround it. The purpose of this post is just to save your time, in case of.

So, after a 12.1.0.2 clusterware installation (on a 2 nodes RAC cluster), I decided to install the 11.2.0.4 database software. I launched the runInstaller, followed the install process until the Step 4:

install11g_db

Continue reading

How to restore the RMAN standby backup to a new server


Assuming that you have already use RMAN to backup your standby database into flashback recovery area (db_recovery_file_dest).

So, if your db_recovery_file_dest=’/recovery_area’, then your backup will be at the following location by default. On the new server create the recovery area and restore the backup.

Default:
/recovery_area/<SID>/backupset
/recovery_area/<SID>/autobackup

On the empty server, we assume you have already cloned the Oracle binaries and set your global variables such as ORACLE_HOME, ORACLE_SID, etc.

Run the RMAN tool and login as sys. Then set your DBID to restore spfile and controlfiles. If you don’t know where your controlfiles are located first restore spfile then create pfile and check the location and then build it if they are not exist.

# rman target /
RMAN> SET DBID xxxxxxxxxxxx;
RMAN> STARTUP FORCE NOMOUNT;
RMAN> show all; — to display default rman configurations.

Continue reading

CLSRSC-184 CLSRSC-258: Failed to configure and start ASM


[root@rac1 ~]# /oracle/app/12.1.0.2/grid/root.sh
Performing root user operation.

The following environment variables are set as:
ORACLE_OWNER= grid
ORACLE_HOME=  /oracle/app/12.1.0.2/grid

Enter the full pathname of the local bin directory: [/usr/local/bin]:
Copying dbhome to /usr/local/bin …
Copying oraenv to /usr/local/bin …
Copying coraenv to /usr/local/bin …

Creating /etc/oratab file…
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /oracle/app/12.1.0.2/grid/crs/install/crsconfig_params
2015/11/21 22:03:46 CLSRSC-4001: Installing Oracle Trace File Analyzer (TFA) Collector.

Continue reading

Oracle 11g RAC database on ASM, ACFS or OCFS2


I see a lot of questions on shared file systems that can be used when people move from single instance to Oracle RAC database and Grid Infrastructure. The most common question is the following: “Should I place archive logs in OCFS2 or ASM or ACFS of 11g?” I’ll try to clarify this topic below.

First we need to understand a separation between Oracle database files and non-database files.

Database files belong to an Oracle database and include control files, data files, archived logs, online redo logs, etc. Oracle ASM is the preferred storage manager for all database files. It has been specifically designed and optimized to provide the best performance for database file types. The file list supported by Oracle ASM becomes longer with every new version and it includes nowadays also spfile, RMAN backupsets and some other file types. You can however use other shared cluster file systems, including OCFS2 to store Oracle RAC database files.

Non-database files are everything that does not belong to database files including Oracle binaries (ORACLE_HOME, etc.). Oracle ACFS is the preferred file manager for non-database files. It is optimized for general purpose files and can be shared across the RAC cluster. You can use both ACFS or local file system, like Ext3 to store Oracle databasebinaries (ORACLE_HOME).

Continue reading