Fix Oem Oracle

4

Click here to load reader

Transcript of Fix Oem Oracle

Page 1: Fix Oem Oracle

Steps to configure Oracle 11g OEM DBConsole manually for an existing databaseIn most of the time DBAs used to go for manual configuration of the database after the database creation. Suppose your

database is cloned from other database where you have grid already installed and configured. After the cloning, in the target

database the same set of configuration will not work. You have to reconfigur e the same.  

For that you have to drop the existing configuration first. If it is a new database you can directly configure the grid using

emca.

Step 1. Drop the existing configuration if it is having sysman user already present.

Connect to sqlplus with sys as sysdba and check SYSMAN is exist or notSQL> Select username from dba_users where username='SYSMAN';

USERNAME------------------------------SYSMAN

           

Command to drop the existing configuration

$ emca -deconfig dbcontrol db -repos drop

STARTED EMCA at Jun 23, 2011 5:27:34 AMEM Configuration Assistant, Version 11.1.0.7.0 ProductionCopyright (c) 2003, 2005, Oracle.   All rights reserved.

Enter the following information:Database SID: prod9Listener port number: 1522Password for SYS user:Password for SYSMAN user:Password for SYSMAN user:Do you wish to continue? [yes(Y)/no(N)]: YJun 23, 2011 5:27:47 AM oracle.sysman.emcp.EMConfig performINFO: This operation is being logged at /data/oracle/cfgtoollogs/emca/prod9/emca_2011_06_23_05_27_34.log.Jun 23, 2011 5:27:49 AM oracle.sysman.emcp.EMDBPreConfig performDeconfigurationWARNING: EM is not configured for this database. No EM-specific actions can be performed.Jun 23, 2011 5:27:50 AM oracle.sysman.emcp.EMReposConfig invokeINFO: Dropping the EM repository (this may take a while) ...Jun 23, 2011 5:37:25 AM oracle.sysman.emcp.EMReposConfig invokeINFO: Repository successfully droppedEnterprise Manager configuration completed successfullyFINISHED EMCA at Jun 23, 2011 5:37:26 AM

Step 2. Create the OEM GRID repository

$ emca -repos create

STARTED EMCA at Jun 23, 2011 6:41:59 AMEM Configuration Assistant, Version 11.1.0.7.0 ProductionCopyright (c) 2003, 2005, Oracle.   All rights reserved.

Enter the following information:Database SID: prod9Listener port number: 1522Password for SYS user:

Page 2: Fix Oem Oracle

Password for SYSMAN user:Do you wish to continue? [yes(Y)/no(N)]: YJun 23, 2011 6:42:17 AM oracle.sysman.emcp.EMConfig performINFO: This operation is being logged at /data/oracle/cfgtoollogs/emca/prod9/emca_2011_06_23_06_41_59.log.Jun 23, 2011 6:42:18 AM oracle.sysman.emcp.EMReposConfig createRepositoryINFO: Creating the EM repository (this may take a while) ...Jun 23, 2011 7:16:31 AM oracle.sysman.emcp.EMReposConfig invokeINFO: Repository successfully createdEnterprise Manager configuration completed successfullyFINISHED EMCA at Jun 23, 2011 7:16:31 AM

Step 4. Confitgure EM Grid control

$ emca -config dbcontrol db

STARTED EMCA at Jun 23, 2011 8:58:47 PMEM Configuration Assistant, Version 11.1.0.7.0 ProductionCopyright (c) 2003, 2005, Oracle.   All rights reserved.

Enter the following information:Database SID: prod9Database Control is already configured for the database prod9You have chosen to configure Database Control for managing the database prod9This will remove the existing configuration and the default settings and perform a fresh configurationDo you wish to continue? [yes(Y)/no(N)]: YListener port number: 1522Password for SYS user:Password for DBSNMP user:Password for SYSMAN user:Password for SYSMAN user: Email address for notifications (optional):Outgoing Mail (SMTP) server for notifications (optional):-----------------------------------------------------------------

You have specified the following settings

Database ORACLE_HOME ................ /data/oracle/product/11.1.0

Local hostname ................ localhostListener port number ................ 1522Database SID ................ prod9Email address for notifications ...............Outgoing Mail (SMTP) server for notifications ...............

-----------------------------------------------------------------Do you wish to continue? [yes(Y)/no(N)]: yJun 23, 2011 8:59:36 PM oracle.sysman.emcp.EMConfig performINFO: This operation is being logged at /data/oracle/cfgtoollogs/emca/prod9/emca_2011_06_23_20_58_47.log.Jun 23, 2011 8:59:41 PM oracle.sysman.emcp.util.DBControlUtil stopOMSINFO: Stopping Database Control (this may take a while) ...Jun 23, 2011 8:59:49 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepositoryINFO: Uploading configuration data to EM repository (this may take a while) ...Jun 23, 2011 9:09:13 PM oracle.sysman.emcp.EMReposConfig invokeINFO: Uploaded configuration data successfullyJun 23, 2011 9:09:36 PM oracle.sysman.emcp.util.DBControlUtil configureSoftwareLibINFO: Software library configured successfully.Jun 23, 2011 9:09:36 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibraryINFO: Deploying Provisioning archives ...Jun 23, 2011 9:10:15 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibraryINFO: Provisioning archives deployed successfully.Jun 23, 2011 9:10:16 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsoleINFO: Securing Database Control (this may take a while) ...Jun 23, 2011 9:11:01 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsoleINFO: Database Control secured successfully.Jun 23, 2011 9:11:01 PM oracle.sysman.emcp.util.DBControlUtil startOMSINFO: Starting Database Control (this may take a while) ...

Page 3: Fix Oem Oracle

Jun 23, 2011 9:13:04 PM oracle.sysman.emcp.EMDBPostConfig performConfigurationINFO: Database Control started successfullyJun 23, 2011 9:13:04 PM oracle.sysman.emcp.EMDBPostConfig performConfigurationINFO: >>>>>>>>>>> The Database Control URL is https://localhost:1158/em <<<<<<<Jun 23, 2011 9:13:20 PM oracle.sysman.emcp.EMDBPostConfig invokeWARNING:************************   WARNING   ************************

Management Repository has been placed in secure mode wherein Enterprise Manager data will be encrypte                                                                                                       ile: /data/oracle/product/11.1.0/localhost_prod9/sysman/config/emkey.ora.     Pleas                                                                                                                 d data will become unusable if this file is lost. ***********************************************************Enterprise Manager configuration completed successfullyFINISHED EMCA at Jun 23, 2011 9:13:20 PM

Step 5. Verify the configuration by typing the address ( https://localhost:1158/em ) in the explorer.

How to check the status of EM Grid control

To check the status of grid control you have issue emctl status dbcontrol

$ emctl status dbconsoleOracle Enterprise Manager 11g Database Control Release 11.1.0.7.0Copyright (c) 1996, 2008 Oracle Corporation.   All rights reserved. https://localhost:1158/em/console/aboutApplicationOracle Enterprise Manager 11g is running.------------------------------------------------------------------Logs are generated in directory /data/oracle/product/11.1.0/localhost_prod9/sysman/log

How to start the EM Grid control

$ emctl start dbconsoleOracle Enterprise Manager 11g Database Control Release 11.1.0.7.0Copyright (c) 1996, 2008 Oracle Corporation.   All rights reserved. https://localhost:1158/em/console/aboutApplicationStarting Oracle Enterprise Manager 11g Database Control ................ started.------------------------------------------------------------------Logs are generated in directory /data/oracle/product/11.1.0/localhost_prod9/sysman/log

How to stop the EM Grid Control?

$ emctl stop dbconsoleOracle Enterprise Manager 11g Database Control Release 11.1.0.7.0Copyright (c) 1996, 2008 Oracle Corporation.   All rights reserved. https://localhost:1158/em/console/aboutApplicationStopping Oracle Enterprise Manager 11g Database Control ...  ...   Stopped.

Page 4: Fix Oem Oracle