Monday, April 15, 2013

Oracle 11g: Configure Enterprise Manager

$ cd $ORACLE_HOME/dbs

$ orapwd file=orapwV10MIG entries=10

Enter password for SYS:

$ ls -l
-rw-r-----   1 oracle   dba         2560 Apr 15 16:19 orapwV10MIG

$ emca -config dbcontrol db

STARTED EMCA at Apr 15, 2013 3:18:48 PM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle.  All rights reserved.

Enter the following information:
Database SID: V10MIG
Listener port number: 1521
Listener ORACLE_HOME [ /usr2/app/oracle/product/11.2.0.3 ]:
Password for SYS user:
Password for DBSNMP 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 ................ /usr2/app/oracle/product/11.2.0.3

Local hostname ................ blackswan
Listener ORACLE_HOME ................ /usr2/app/oracle/product/11.2.0.3
Listener port number ................ 1521
Database SID ................ V10MIG
Email address for notifications ...............
Outgoing Mail (SMTP) server for notifications ...............

-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Apr 15, 2013 3:19:12 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /usr2/app/oracle/cfgtoollogs/emca/V10MIG/emca_2013_04_15_15_18_48.log.
Apr 15, 2013 3:19:17 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository
INFO: Uploading configuration data to EM repository (this may take a while) ...
Apr 15, 2013 3:21:01 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Uploaded configuration data successfully
Apr 15, 2013 3:21:02 PM oracle.sysman.emcp.ParamsManager getLocalListener
WARNING: Error retrieving listener for blackswan
Apr 15, 2013 3:21:03 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Apr 15, 2013 3:21:10 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Apr 15, 2013 3:21:11 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Apr 15, 2013 3:24:27 PM oracle.sysman.emcp.util.PlatformInterface executeCommand
WARNING: Error executing /usr2/app/oracle/product/11.2.0.3/bin/emctl start dbconsole
Apr 15, 2013 3:24:27 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://blackswan:1158/em <<<<<<<<<<<
Apr 15, 2013 3:24:29 PM oracle.sysman.emcp.EMDBPostConfig invoke
WARNING:
************************  WARNING  ************************

Management Repository has been placed in secure mode wherein Enterprise Manager data will be encrypted.  The encryption key has been placed in the file: /usr2/app/oracle/product/11.2.0.3/blackswan_V10MIG/sysman/config/emkey.ora. Ensure this file is backed up as the encrypted data will become unusable if this file is lost.

***********************************************************
Apr 15, 2013 3:24:29 PM oracle.sysman.emcp.EMDBPostConfig invoke
WARNING: Error starting Database Control.Execute the following command(s).

 1) Set the environment variable ORACLE_UNQNAME to Database unique name
 2) /usr2/app/oracle/product/11.2.0.3/bin/emctl start dbconsole


Error starting Database Control.Execute the following command(s).

 1) Set the environment variable ORACLE_UNQNAME to Database unique name
 2) /usr2/app/oracle/product/11.2.0.3/bin/emctl start dbconsole

 Disable secure
 $ emctl unsecure dbconsole
Oracle Enterprise Manager 11g Database Control Release 11.2.0.3.0
Copyright (c) 1996, 2011 Oracle Corporation.  All rights reserved.
https://blackswan:1158/em/console/aboutApplication
Configuring DBConsole for HTTP...   Done.
DBCONSOLE already stopped...   Done.
Agent is already stopped...   Done.
Unsecuring dbconsole...   Started.
DBConsole is now unsecured...  Done.
Unsecuring dbconsole...  Sucessful.



Using EMCA When Database Host Name or IP Address Changes

When the database host name (including the domain name) or the IP address changes, deconfigure and then reconfigure the Database Console with the repository create command. Run the following command:
emca -deconfig dbcontrol db -repos drop
emca -config dbcontrol db -repos create
or
emca -deconfig dbcontrol db
emca -config dbcontrol db -repos recreate

Using EMCA When the TNS Configuration Is Changed

When the TNS configuration is changed, set the environment variable and then run the following command:
emca -config dbcontrol db

No comments:

Post a Comment