DBA Tips Archive for Oracle

  


How to Recreate the Database Control Repository - (Oracle10g R2)

by Jeff Hunter, Sr. Database Administrator

Contents

Introduction

This article provides steps-by-step details on how to create, drop and recreate the Database Control Repository and configuration files in an Oracle 10g R2 database.

Create Database Console

To create the configuration files and repository for Database Console, run:


$ emca -config dbcontrol db -repos create STARTED EMCA at Jul 24, 2006 9:59:39 PM EM Configuration Assistant, Version 10.2.0.1.0 Production Copyright (c) 2003, 2005, Oracle. All rights reserved. Enter the following information: Database SID: TESTDB Listener port number: 1521 Password for SYS user: change_on_install Password for DBSNMP user: manager Password for SYSMAN user: manager Email address for notifications (optional): Outgoing Mail (SMTP) server for notifications (optional): ----------------------------------------------------------------- You have specified the following settings Database ORACLE_HOME ................ /u01/app/oracle/product/10.2.0/db_1 Database hostname ................ linux3 Listener port number ................ 1521 Database SID ................ TESTDB Email address for notifications ............... Outgoing Mail (SMTP) server for notifications ............... ----------------------------------------------------------------- Do you wish to continue? [yes(Y)/no(N)]: Y Jul 24, 2006 10:00:12 PM oracle.sysman.emcp.EMConfig perform INFO: This operation is being logged at /u01/app/oracle/product/10.2.0/db_1/cfgtoollogs/emca/TESTDB/emca_2006-07-24_09-59-39-PM.log. Jul 24, 2006 10:00:15 PM oracle.sysman.emcp.EMReposConfig createRepository INFO: Creating the EM repository (this may take a while) ... Jul 24, 2006 10:05:51 PM oracle.sysman.emcp.EMReposConfig invoke INFO: Repository successfully created Jul 24, 2006 10:06:01 PM oracle.sysman.emcp.util.DBControlUtil startOMS INFO: Starting Database Control (this may take a while) ... Jul 24, 2006 10:07:49 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration INFO: Database Control started successfully Jul 24, 2006 10:07:49 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration INFO: >>>>>>>>>>> The Database Control URL is http://linux3:1158/em <<<<<<<<<<< Enterprise Manager configuration completed successfully FINISHED EMCA at Jul 24, 2006 10:07:49 PM

Drop Database Console

To drop (remove) the configuration files and repository for Database Console, run:


$ emca -deconfig dbcontrol db -repos drop STARTED EMCA at Jul 24, 2006 9:53:55 PM EM Configuration Assistant, Version 10.2.0.1.0 Production Copyright (c) 2003, 2005, Oracle. All rights reserved. Enter the following information: Database SID: TESTDB Listener port number: 1521 Password for SYS user: change_on_install Password for SYSMAN user: manager Do you wish to continue? [yes(Y)/no(N)]: Y Jul 24, 2006 9:54:15 PM oracle.sysman.emcp.EMConfig perform INFO: This operation is being logged at /u01/app/oracle/product/10.2.0/db_1/cfgtoollogs/emca/TESTDB/emca_2006-07-24_09-53-55-PM.log. Jul 24, 2006 9:54:16 PM oracle.sysman.emcp.util.DBControlUtil stopOMS INFO: Stopping Database Control (this may take a while) ... Jul 24, 2006 9:54:35 PM oracle.sysman.emcp.EMReposConfig dropRepository INFO: Dropping the EM repository (this may take a while) ... Jul 24, 2006 9:56:48 PM oracle.sysman.emcp.EMReposConfig invoke INFO: Repository successfully dropped Enterprise Manager configuration completed successfully FINISHED EMCA at Jul 24, 2006 9:56:48 PM

Recreate Database Console

To recreate the configuration files and repository for Database Console, run:


$ emca -config dbcontrol db -repos recreate STARTED EMCA at Jul 24, 2006 10:08:20 PM EM Configuration Assistant, Version 10.2.0.1.0 Production Copyright (c) 2003, 2005, Oracle. All rights reserved. Enter the following information: Database SID: TESTDB Database Control is already configured for the database TESTDB You have chosen to configure Database Control for managing the database TESTDB This will remove the existing configuration and the default settings and perform a fresh configuration Do you wish to continue? [yes(Y)/no(N)]: Y Listener port number: 1521 Password for SYS user: change_on_install Password for DBSNMP user: manager Password for SYSMAN user: manager Email address for notifications (optional): Outgoing Mail (SMTP) server for notifications (optional): ----------------------------------------------------------------- You have specified the following settings Database ORACLE_HOME ................ /u01/app/oracle/product/10.2.0/db_1 Database hostname ................ linux3 Listener port number ................ 1521 Database SID ................ TESTDB Email address for notifications ............... Outgoing Mail (SMTP) server for notifications ............... ----------------------------------------------------------------- Do you wish to continue? [yes(Y)/no(N)]: Y Jul 24, 2006 10:08:50 PM oracle.sysman.emcp.EMConfig perform INFO: This operation is being logged at /u01/app/oracle/product/10.2.0/db_1/cfgtoollogs/emca/TESTDB/emca_2006-07-24_10-08-20-PM.log. Jul 24, 2006 10:08:53 PM oracle.sysman.emcp.util.DBControlUtil stopOMS INFO: Stopping Database Control (this may take a while) ... Jul 24, 2006 10:09:29 PM oracle.sysman.emcp.EMReposConfig dropRepository INFO: Dropping the EM repository (this may take a while) ... Jul 24, 2006 10:11:23 PM oracle.sysman.emcp.EMReposConfig invoke INFO: Repository successfully dropped Jul 24, 2006 10:11:23 PM oracle.sysman.emcp.EMReposConfig createRepository INFO: Creating the EM repository (this may take a while) ... Jul 24, 2006 10:15:09 PM oracle.sysman.emcp.EMReposConfig invoke INFO: Repository successfully created Jul 24, 2006 10:15:18 PM oracle.sysman.emcp.util.DBControlUtil startOMS INFO: Starting Database Control (this may take a while) ... Jul 24, 2006 10:17:21 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration INFO: Database Control started successfully Jul 24, 2006 10:17:22 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration INFO: >>>>>>>>>>> The Database Control URL is http://linux3:1158/em <<<<<<<<<<< Enterprise Manager configuration completed successfully FINISHED EMCA at Jul 24, 2006 10:17:22 PM

Using EMCA with Real Application Clusters

In this section, I will be using two Database Control consoles running; one on linux1 and the other on linux2. From either of these consoles, you can manage and monitor all targets in the cluster.

Troubleshooting EMCA

If you have any problems when running emca, check the log file under:


ORACLE_HOME/cfgtoollogs/emca/<ORACLE_SID>/

Further Reading

Additional information on emca command-line options can be found in the Oracle Enterprise Manager 10g Advanced Configuration Guide. This guide is available from OTN at the following address http://download-east.oracle.com/docs/cd/B19306_01/em.102/b16242.pdf.

About the Author

Jeffrey Hunter is an Oracle Certified Professional, Java Development Certified Professional, Author, and an Oracle ACE. Jeff currently works as a Senior Database Administrator for The DBA Zone, Inc. located in Pittsburgh, Pennsylvania. His work includes advanced performance tuning, Java and PL/SQL programming, developing high availability solutions, capacity planning, database security, and physical / logical database design in a UNIX, Linux, and Windows server environment. Jeff's other interests include mathematical encryption theory, programming language processors (compilers and interpreters) in Java and C, LDAP, writing web-based database administration tools, and of course Linux. He has been a Sr. Database Administrator and Software Engineer for over 18 years and maintains his own website site at: http://www.iDevelopment.info. Jeff graduated from Stanislaus State University in Turlock, California, with a Bachelor's degree in Computer Science.



Copyright (c) 1998-2012 Jeffrey M. Hunter. All rights reserved.

All articles, scripts and material located at the Internet address of http://www.idevelopment.info is the copyright of Jeffrey M. Hunter and is protected under copyright laws of the United States. This document may not be hosted on any other site without my express, prior, written permission. Application to host any of the material elsewhere can be made by contacting me at jhunter@idevelopment.info.

I have made every effort and taken great care in making sure that the material included on my web site is technically accurate, but I disclaim any and all responsibility for any loss, damage or destruction of data or any other property which may arise from relying on it. I will in no case be liable for any monetary damages arising from such loss, damage or destruction.

Last modified on
Thursday, 18-Nov-2010 16:49:17 EST
Page Count: 2724