I am trying to start EM on my newly created database, while starting EM, getting failed with OC4J Configuration issue… while diagnosed there is no OC4J_DBConsole_localhost directory exist in ORACLE_HOME. Means this may be the case where Database Control not configured while database created OR misconfigured.
Error log:
[oracle@localhost ~]$ emctl status dbconsole
OC4J Configuration issue. /u01/app/oracle/product/11.2.0/dbhome_1/oc4j/j2ee/OC4J_DBConsole_localhost.localhost.com_fmw not found.
[oracle@localhost ~]$ emctl start dbconsole
OC4J Configuration issue. /u01/app/oracle/product/11.2.0/dbhome_1/oc4j/j2ee/OC4J_DBConsole_localhost.localhost.com_fmw not found.
This is due to a misconfiguration of dbconsole during database setup. The fastest solution is usually to recreate repository and configuration.
Solution: is to Configure EM with the help of following “Enterprise Manager Configuration Assistant” (i.e. emca) utility from Oracle user Before that:
1. Ensure environment variable properly set like below.
2. Ensure your listener properly configured and started.
3. Ensure password file is created. (Optional)
4. You need SYS,SYSMAN & DBSNMP password.
5. Ensure your /etc/hosts file mentioned below two lines.
Environment Variable
[oracle@localhost~]$ export ORACLE_SID=orcl [oracle@localhost~]$ export ORACLE_UNQNAME=orcl [oracle@localhost~]$ export ORACLE_HOME=/home/oracle/app/oracle/product/11.2.0/dbhome_1/ [oracle@localhost~]$ export PATH=$PATH:/home/oracle/app/oracle/product/11.2.0/dbhome_1/bin/First, deconfigure dbconsole:
[oracle@localhost ~]$ emca -deconfig dbcontrol db -repos dropSTARTED EMCA at Aug 5, 2013 7:54:35 PM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Enter the following information:
Database SID: fmw
Listener port number: 1521
Password for SYS user:
Password for SYSMAN user:
Do you wish to continue? [yes(Y)/no(N)]: Y
Aug 5, 2013 7:54:54 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/fmw/emca_2013_08_05_19_54_34.log.
Aug 5, 2013 7:54:55 PM oracle.sysman.emcp.EMDBPreConfig performDeconfiguration
WARNING: EM is not configured for this database. No EM-specific actions can be performed.
Aug 5, 2013 7:54:55 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Dropping the EM repository (this may take a while) …
Aug 5, 2013 7:57:04 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully dropped
Enterprise Manager configuration completed successfully
FINISHED EMCA at Aug 5, 2013 7:57:04 PM
Now, let’s configure it again
[oracle@localhost ~]$ emca -config dbcontrol db -repos createSTARTED EMCA at Aug 5, 2013 7:58:22 PM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Enter the following information:
Database SID: fmw
Listener port number: 1521
Listener ORACLE_HOME [ /u01/app/oracle/product/11.2.0/dbhome_1 ]:
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 ……………. /u01/app/oracle/product/11.2.0/dbhome_1
Local hostname ……………. localhost.localhost.com
Listener ORACLE_HOME ……………. /u01/app/oracle/product/11.2.0/dbhome_1
Listener port number ……………. 1521
Database SID ……………. fmw
Email address for notifications ……………
Outgoing Mail (SMTP) server for notifications ……………
—————————————————————–
Do you wish to continue? [yes(Y)/no(N)]: Y
Aug 5, 2013 7:58:53 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/fmw/emca_2013_08_05_19_58_21.log.
Aug 5, 2013 7:58:54 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) …
Aug 5, 2013 8:05:56 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Aug 5, 2013 8:06:02 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository
INFO: Uploading configuration data to EM repository (this may take a while) …
Aug 5, 2013 8:07:14 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Uploaded configuration data successfully
Aug 5, 2013 8:07:17 PM oracle.sysman.emcp.util.DBControlUtil configureSoftwareLib
INFO: Software library configured successfully.
Aug 5, 2013 8:07:17 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Deploying Provisioning archives …
Aug 5, 2013 8:08:07 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Provisioning archives deployed successfully.
Aug 5, 2013 8:08:07 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) …
Aug 5, 2013 8:08:53 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Aug 5, 2013 8:08:53 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) …
Aug 5, 2013 8:10:16 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Aug 5, 2013 8:10:17 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://localhost.localhost.com:5500/em <<<<<<<<<<<
Aug 5, 2013 8:10:28 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: /u01/app/oracle/product/11.2.0/dbhome_1/localhost.localhost.com_fmw/sysman/config/emkey.ora. Please ensure this file is backed up as the encrypted data will become unusable if this file is lost.
***********************************************************
Enterprise Manager Configuration completed successfully
FINISHED EMCA at Aug 5, 2013 8:10:28 PM
To access your Enterprise Manager, Browse URL: https://localhost.localdomain:5500/em.