RMAN DBname: RMN1 tablespace name: rman_tbs datafile name: rman01.dbf (size 100M) on the prompt: $ dbca & step-1: pick singel instance database on the Database Configuration Assistant: Welcome Screen. step-2: Pick Create a Database option step-3: Pick Custom Database on the database template. This is because you don't want any sample schemas in you RMAN database. step-4: Type "RMN1" rman database global name Step-5: Disselect "Configure the Database with Enterprise Manager" option, this is due to the fact that you're creating rman database to manage your recovery catalog and you don't want to overload this small database with stuff unneccesary. step-6: Type password for sys/system login and save it in the safe place as we will require this login credentials later to manage catalog database. step-7: Select "File System" option from Storage Mechanishm step-8: select "Use Database File Locations from template" option to choose for datafile storage or you can choose Oracle-Managed Files option. step-9: Make sure you Specify Flash Recovery Area Step-10: Choose appropriate memory for the rman database depending upon your need. i go with about 300MB SGA size and 120MB for PGA. Step-11: Confirm the summary of parameters and other items and click Finish to start database creation. Verify database creation: $ export ORACLE_SID=RMN1 $ sqlplus rman/password@RMN1 Now you are ready to create rman recovery catalog database and register target database. Go to the following link:
Creating a Rman Recovery Catalog
Creating RMAN database to manage recovery catalog.
Labels:
RMAN
Creating a Recovery Catalog in RAC Environment
It is highly recommended that you create rman database in seperate server than having in the same server where RAC databases is intalled and are running. This would cause not only performance issues but also if server crashes and data is not recoverable, you are going to loose literally everything costing millions of dollors and hashles. Create a RMAN database (RMN1) ============================================================= Create a tablespace in the new database (RMN1) ============================================ $ sqlplus /nolog CONNECT SYS/passwd@RMN1 AS SYSDBA; CREATE TABLESPACE rman_tbs DATAFILE '/u01/app/oracle/oradata/RMAN/rman01.dbf' size 100m; Create the Recovery Catalog Owner in the new database (RMN1) ============================================================== CREATE USER rman IDENTIFIED BY rman DEFAULT TABLESPACE rman_tbs QUOTA UNLIMITED ON rman_tbs; Grant the necessary privileges to the schema owner(rman) ============================================================= SQL> GRANT connect, resource, recovery_catalog_owner TO rman; "RECOVERY_CATALOG_OWNER" role provides the user with all privileges required to maintain and query the recovery catalog Creating the Recovery Catalog ============================================================== Connect to the RMN1 database which will contain the recovery catalog. For example: $ rman catalog rman/passwd@RMN1 Recovery Manager: Release 10.2.0.4.0 - Production on Mon Apr 10 18:22:00 2009 Copyright (c) 1982, 2005, Oracle. All rights reserved. connected to recovery catalog database RMAN> Run the CREATE CATALOG command to create the catalog ====================================================== RMAN> CREATE CATALOG; recovery catalog created Registering a Database in the Recovery Catalog ======================================================= Connect to the target database (ORCL) and recovery catalog database (RMN1). $ export ORACLE_SID=ORCL; $ rman target / catalog rman/passwd@RMN1; Recovery Manager: Release 10.2.0.4.0 - Production on Mon Apr 10 18:44:10 2009 Copyright (c) 1982, 2005, Oracle. All rights reserved. connected to target database: ORCL (DBID=1679521370) connected to recovery catalog database RMAN> REGISTER DATABASE; database registered in recovery catalog starting full resync of recovery catalog full resync complete Make sure that the registration was successful by running REPORT SCHEMA: RMAN> REPORT SCHEMA; Now in RAC environment regardless of what node you are working on, you can use the same networked rman database and rman user to take backup and manage other jobs. if you have multiple databases installed then you must register each target database in the recovery catalog to manage and maintain RMAN backups and other rman tasks. Here is how you will register cluster databases: $ export ORACLE_SID=DEV $ rman target / catalog rman/passwd@RMN1; RMAN> REGISTER DATABASE; database registered in recovery catalog starting full resync of recovery catalog full resync complete Make sure that the registration was successful by running REPORT SCHEMA: RMAN> REPORT SCHEMA;
Labels:
RMAN
CRS-0184: Cannot communicate with CRS daemon.
Solution: a) check permission in raw devices # ls -lrt /dev/raw/raw* Permission should be for oracle user NOT for root. execute the following as a root user. chown oracle:oinstall /dev/raw/raw1 chown oracle:oinstall /dev/raw/raw2 chown oracle:oinstall /dev/raw/raw3 chown oracle:oinstall /dev/raw/raw4 chown oracle:oinstall /dev/raw/raw5 chmod 600 /dev/raw/raw1 chmod 600 /dev/raw/raw2 chmod 600 /dev/raw/raw3 chmod 600 /dev/raw/raw4 chmod 600 /dev/raw/raw5
How to Find DB Size in Oracle?
SELECT name, bytes from v$datafile; OR SELECT SUBSTR (df.NAME, 1, 40) file_name, df.bytes / 1024 / 1024 allocated_mb, ((df.bytes / 1024 / 1024) - NVL (SUM (dfs.bytes) / 1024 / 1024, 0)) used_mb, NVL (SUM (dfs.bytes) / 1024 / 1024, 0) free_space_mb FROM v$datafile df, dba_free_space dfs WHERE df.file# = dfs.file_id(+) GROUP BY dfs.file_id, df.NAME, df.file#, df.bytes ORDER BY file_name;
Subscribe to:
Posts (Atom)