Welcome 微信登录

首页 / 数据库 / MySQL / Oracle 入门之EM配置

Oracle 11g R2 64位启动em,出现如下错误:
[root@localhost ~]# su - oracle
[oracle@localhost ~]$ emctl start dbconsole
Environment variable ORACLE_UNQNAME not defined. Please set ORACLE_UNQNAME to database unique name.
[oracle@localhost ~]$ export ORACLE_UNQNAME=online
[oracle@localhost ~]$ emctl start dbconsole
OC4J Configuration issue. /u01/app/oracle/oc4j/j2ee/OC4J_DBConsole_localhost.localdomain_online not found.
问题原因为em资料库配置不正确,或者是dbcontrol没有配置好1:重建EM资料
[oracle@localhost ~]$ emca -repos recreateSTARTED EMCA at Sep 6, 2010 4:42:53 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: online
Listener port number: 1521
Password for SYS user:
Password for SYSMAN user: Do you wish to continue? [yes(Y)/no(N)]: y
Sep 6, 2010 4:43:30 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/cfgtoollogs/emca/online/emca_2010_09_06_16_42_52.log.
Sep 6, 2010 4:43:31 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Dropping the EM repository (this may take a while) ...
Sep 6, 2010 4:46:23 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully dropped
Sep 6, 2010 4:46:24 PM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Sep 6, 2010 4:53:00 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Enterprise Manager configuration completed successfully
FINISHED EMCA at Sep 6, 2010 4:53:00 PM2:配置dbcontrol
[oracle@localhost ~]$ emca -config dbcontrol dbSTARTED EMCA at Sep 6, 2010 5:02:57 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: online
Listener port number: 1521
Listener ORACLE_HOME [ /u01/app/oracle ]:
Password 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 settingsDatabase ORACLE_HOME ................ /u01/app/oracleLocal hostname ................ localhost.localdomain
Listener ORACLE_HOME ................ /u01/app/oracle
Listener port number ................ 1521
Database SID ................ online
Email address for notifications ...............
Outgoing Mail (SMTP) server for notifications ............... -----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
Sep 6, 2010 5:03:34 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/cfgtoollogs/emca/online/emca_2010_09_06_17_02_56.log.
Sep 6, 2010 5:03:39 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository
INFO: Uploading configuration data to EM repository (this may take a while) ...
Sep 6, 2010 5:04:45 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Uploaded configuration data successfully
Sep 6, 2010 5:04:46 PM oracle.sysman.emcp.ParamsManager getLocalListener
WARNING: Error retrieving listener for localhost.localdomain
Sep 6, 2010 5:04:49 PM oracle.sysman.emcp.util.DBControlUtil configureSoftwareLib
INFO: Software library configured successfully.
Sep 6, 2010 5:04:49 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Deploying Provisioning archives ...
Sep 6, 2010 5:05:22 PM oracle.sysman.emcp.EMDBPostConfig configureSoftwareLibrary
INFO: Provisioning archives deployed successfully.
Sep 6, 2010 5:05:22 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Sep 6, 2010 5:06:17 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Database Control secured successfully.
Sep 6, 2010 5:06:17 PM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Sep 6, 2010 5:07:00 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Sep 6, 2010 5:07:00 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://localhost.localdomain:1158/em <<<<<<<<<<<
Sep 6, 2010 5:07:04 PM oracle.sysman.emcp.EMDBPostConfig invoke
WARNING: 可以看到em已经启动:
[oracle@localhost ~]$ netstat -ntpl |grep 1158
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp        0      0 :::1158                     :::*                        LISTEN      11125/java         
[oracle@localhost ~]$ emctl status dbconsole
Oracle Enterprise Manager 11g Database Control Release 11.2.0.1.0
Copyright (c) 1996, 2009 Oracle Corporation. All rights reserved.
https://localhost.localdomain:1158/em/console/aboutApplication
Oracle Enterprise Manager 11g is running.
------------------------------------------------------------------
Logs are generated in directory /u01/app/oracle/localhost.localdomain_online/sysman/log
************************ 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/localhost.localdomain_online/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 Sep 6, 2010 5:07:04 PM连接测试:Oracle中关于处理小数点位数的几个函数Linux下如何自动启动Oracle服务相关资讯      oracle 
  • [INS-32052] Oracle基目录和Oracle  (07/22/2014 07:41:41)
  • Oracle 4个大对象(lobs)数据类型  (02/03/2013 12:33:05)
  • Oracle按时间段分组统计  (07/26/2012 10:36:48)
  • [Oracle] dbms_metadata.get_ddl的  (07/12/2013 07:37:30)
  • Liferay Portal 配置使用Oracle和  (07/31/2012 20:07:18)
  • Concurrent Request:Inactive   (07/20/2012 07:44:05)
本文评论 查看全部评论 (2)
表情: 姓名: 字数


评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的??论
  • 参与本评论即表明您已经阅读并接受上述条款
第 2 楼 匿名 发表于 2013/3/13 14:51:33
回复 Fuping 的评论sh-4.1$ emca -repos recreate

STARTED EMCA at Apr 3, 2011 3:12:14 AM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle.All rights reserved.

Enter the following information:
Database SID: orcl
Database SID: Listener port number: 1521
Password for SYS user:
Password for SYSMAN user:

Do you wish to continue? [yes(Y)/no(N)]: y
Apr 3, 2011 3:12:34 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /host/u01/oracle/app/oracle/cfgtoollogs/emca/orcl/emca_2011_04_03_03_12_13.log.
Apr 3, 2011 3:12:34 AM oracle.sysman.emcp.EMConfig perform
SEVERE: Listener is not up or database service is not registered with it. Start the Listener and register database service and run EM Configuration Assistant again .
Refer to the log file at /host/u01/oracle/app/oracle/cfgtoollogs/emca/orcl/emca_2011_04_03_03_12_13.log for more details.
Could not complete the configuration. Refer to the log file at /host/u01/oracle/ap
vi /etc/sysconfig/network
NETWORKING=yes
NETWORKING_IPV6=no
H**TNAME=test11g
GATEWAY=192.168.192.254

vi /etc/h**ts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localh**t.localdomain localh**t test11g
::1 localh**t6.localdomain6 localh**t6回复 支持 (0) 反对 (0)第 1 楼 Fuping 发表于 2011/4/3 3:16:13sh-4.1$ emca -repos recreate

STARTED EMCA at Apr 3, 2011 3:12:14 AM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle.All rights reserved.

Enter the following information:
Database