DB Console start errorOC4J Configuration issue

下面是一个模拟的 OC4J Configuration issue. 的错误,
我手工 删除一个EM资料库   删除数据库的 Database Control配置   ,在启动 oem时就会出现下面的错误,如果存在em 资料库 ,就不用执行下面绿色部分的内容
[oracle@huang14 ~]$  emctl start dbconsole
TZ set to PRC
OC4J Configuration issue. /opt/oracle/10g/oc4j/j2ee/OC4J_DBConsole_huang14.huang.com_orcl not found. 
[oracle@huang14 ~]$ emca -repos create;
STARTED EMCA at Feb 11, 2010 4:30:48 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: orcl
Listener port number: 1521
Password for SYS user:  
Password for SYSMAN user:  
Do you wish to continue? [yes(Y)/no(N)]: y
Feb 11, 2010 4:30:55 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-30-48-PM.log.
Feb 11, 2010 4:30:55 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Feb 11, 2010 4:30:55 PM oracle.sysman.emcp.EMReposConfig invoke
SEVERE: Error creating the repository
Feb 11, 2010 4:30:55 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Refer to the log file at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_repos_create_<date>.log for more details.
Feb 11, 2010 4:30:55 PM oracle.sysman.emcp.EMConfig perform
SEVERE: Error creating the repository
Refer to the log file at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-30-48-PM.log for more details.
Could not complete the configuration. Refer to the log file at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-30-48-PM.log for more details.
[oracle@huang14 ~]$ grep ORA /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-30-48-PM.log
CONFIG: Setting param: ORACLE_HOME value: /opt/oracle/10g
CONFIG: ORA-20001: SYSMAN already exists..
ORA-06512: at line 17
oracle.sysman.assistants.util.sqlEngine.SQLFatalErrorException: ORA-20001: SYSMAN already exists..
ORA-06512: at line 17
[oracle@huang14 ~]$ sqlplus / as sysdba
[uniread] Loaded history (777 lines)
SQL*Plus: Release 10.2.0.4.0 - Production on Thu Feb 11 16:31:47 2010
Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
SQL> drop user sysman cascade;
User dropped.
SQL> drop role MGMT_USER;
Role dropped.
SQL> drop user MGMT_VIEW cascade;
User dropped.
SQL> drop public synonym MGMT_TARGET_BLACKOUTS;
Synonym dropped.
SQL> drop public synonym SETEMVIEWUSERCONTEXT;
Synonym dropped.
[oracle@huang14 ~]$ emca -repos create;
STARTED EMCA at Feb 11, 2010 4:33:09 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: orcl
Listener port number: 1521
Password for SYS user:  
Password for SYSMAN user:  
Do you wish to continue? [yes(Y)/no(N)]: y
Feb 11, 2010 4:33:17 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-33-09-PM.log.
Feb 11, 2010 4:33:17 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Feb 11, 2010 4:35:35 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Enterprise Manager configuration completed successfully
FINISHED EMCA at Feb 11, 2010 4:35:35 PM
[oracle@huang14 ~]$  emca -config dbcontrol db
STARTED EMCA at Feb 11, 2010 4:36:19 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: orcl
Listener port number: 1521
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 ................ /opt/oracle/10g
Database hostname ................ huang14.huang.com
Listener port number ................ 1521
Database SID ................ orcl
Email address for notifications ............... 
Outgoing Mail (SMTP) server for notifications ............... 
-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Feb 11, 2010 4:36:34 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_04-36-19-PM.log.
Feb 11, 2010 4:36:47 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Feb 11, 2010 4:38:41 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Feb 11, 2010 4:38:42 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Feb 11, 2010 4:40:28 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Feb 11, 2010 4:40:28 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://huang14.huang.com:1158/em <<<<<<<<<<<
Enterprise Manager configuration completed successfully
FINISHED EMCA at Feb 11, 2010 4:40:28 PM
[oracle@huang14 ~]$  emctl status dbconsole
TZ set to PRC
Oracle Enterprise Manager 10g Database Control Release 10.2.0.4.0  
Copyright (c) 1996, 2007 Oracle Corporation.  All rights reserved.
https://huang14.huang.com:1158/em/console/aboutApplication
Oracle Enterprise Manager 10g is running. 
------------------------------------------------------------------
Logs are generated in directory /opt/oracle/10g/huang14.huang.com_orcl/sysman/log 
[oracle@huang14 ~]$  netstat -an|grep 1158
tcp        0      0 0.0.0.0:1158                0.0.0.0:*                   LISTEN
输入https://ip:1158/em就可以访问了。记住加上https
如果不能访问的时候我们可以手动指定一下oem的访问端口。
[oracle@huang14 ~]$ emca -reconfig ports -dbcontrol_http_prot 1158
STARTED EMCA at Feb 11, 2010 5:01:33 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: orcl
Do you wish to continue? [yes(Y)/no(N)]: y
Feb 11, 2010 5:01:36 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /opt/oracle/10g/cfgtoollogs/emca/orcl/emca_2010-02-11_05-01-33-PM.log.
Feb 11, 2010 5:01:37 PM oracle.sysman.emcp.util.DBControlUtil stopOMS
INFO: Stopping Database Control (this may take a while) ...
Feb 11, 2010 5:01:48 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Feb 11, 2010 5:03:33 PM oracle.sysman.emcp.EMDBPostConfig performReconfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://huang14.huang.com:1158/em <<<<<<<<<<<
Enterprise Manager configuration completed successfully
FINISHED EMCA at Feb 11, 2010 5:03:33 PM

你可能感兴趣的:(oracle,职场,休闲)