[root@HZ-NOAH-12-126 ~]# echo $ORACLE_HOME
/oracle/ora11/product
[root@HZ-NOAH-12-126 ~]# echo $ORACLE_SID
ora11g
[root@HZ-NOAH-12-126 ~]# echo $PATH
/usr/lib64/qt-3.3/bin:/oracle/ora11/product/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/sbin:/sbin:/root/bin
但是运行:
[root@HZ-NOAH-12-126 ~]# emctl status dbconsole
Environment variable ORACLE_UNQNAME not defined. Please set ORACLE_UNQNAME to database unique name.
[root@HZ-NOAH-12-126 ~]# export ORACLE_UNQNAME=ora11g
[root@HZ-NOAH-12-126 ~]# emctl status dbconsole
OC4J Configuration issue. /oracle/ora11/product/oc4j/j2ee/OC4J_DBConsole_HZ-NOAH-12-126_ora11g not found.
请问怎么打开oracle11g数据库的database control
4 个解决方案
#1
/oracle/ora11/product/oc4j/j2ee/
--这里是你的Oracle安装目录
OC4J_DBConsole_HZ-NOAH-12-126_ora11g
--这里是一个文件夹
HZ-NOAH-12-126
--这里一般是你主机的名字
ora11g
--这里是你数据库的SID
以上都对了就能进去了。
--这里是你的Oracle安装目录
OC4J_DBConsole_HZ-NOAH-12-126_ora11g
--这里是一个文件夹
HZ-NOAH-12-126
--这里一般是你主机的名字
ora11g
--这里是你数据库的SID
以上都对了就能进去了。
#2
是不是安装有问题哦,一般使用向导安装完直接$emctl start dbconsole就起来了,顶多字符编码等问题设置设置~
#3
重建一下
emca -config dbcontrol db -repos recreate
emca -config dbcontrol db -repos recreate
#4
重启后报错如下:
[root@HZ-NOAH-12-126 ~]# su - oracle
[oracle@HZ-NOAH-12-126 ~]$ emca -config dbcontrol db -repos recreate
STARTED EMCA at May 16, 2012 9:04:54 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database SID: ora11g
Listener port number: 1158
Listener ORACLE_HOME [ /oracle/ora11/product ]: /oracle/ora11/product
Password for SYS user:
Password for DBSNMP user:
May 16, 2012 9:07:31 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
WARNING: ORA-28000: the account is locked
Password for SYSMAN user:
Email address for notifications (optional): 897600325@qq.com
Outgoing Mail (SMTP) server for notifications (optional): greenandtree@163.com
-----------------------------------------------------------------
You have specified the following settings
Database ORACLE_HOME ................ /oracle/ora11/product
Local hostname ................ HZ-NOAH-12-126
Listener ORACLE_HOME ................ /oracle/ora11/product
Listener port number ................ 1158
Database SID ................ ora11g
Email address for notifications ............... 897600325@qq.com
Outgoing Mail (SMTP) server for notifications ............... greenandtree@163.com
-----------------------------------------------------------------
----------------------------------------------------------------------
WARNING : While repository is dropped the database will be put in quiesce mode.
----------------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
May 16, 2012 9:08:14 AM oracle.sysman.emcp.util.EMCALogManager addLogFileInternal
WARNING: Adding log file /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log failed. Messages will not be logged in this file.
May 16, 2012 9:08:14 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log.
May 16, 2012 9:08:15 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: ORA-12541: TNS:no listener
May 16, 2012 9:08:15 AM oracle.sysman.emcp.EMConfig perform
SEVERE:
Database connection through listener failed. Fix the error and run EM Configuration Assistant again.
Some of the possible reasons may be:
1) Listener port 1158 provided is incorrect. Provide the correct port.
2) Listener is not up. Start the Listener.
3) Database service ora11g is not registered with listener. Register the database service.
4) Listener is up on physical host and ORACLE_HOSTNAME environment variable is set to virtual host. Unset ORACLE_HOSTNAME environment variable.
5) Listener is up on virtual host. Set environment variable ORACLE_HOSTNAME=<virtual host>.
6) /etc/hosts does not have correct entry for hostname.
Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
Could not complete the configuration. Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
[root@HZ-NOAH-12-126 ~]# su - oracle
[oracle@HZ-NOAH-12-126 ~]$ emca -config dbcontrol db -repos recreate
STARTED EMCA at May 16, 2012 9:04:54 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database SID: ora11g
Listener port number: 1158
Listener ORACLE_HOME [ /oracle/ora11/product ]: /oracle/ora11/product
Password for SYS user:
Password for DBSNMP user:
May 16, 2012 9:07:31 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
WARNING: ORA-28000: the account is locked
Password for SYSMAN user:
Email address for notifications (optional): 897600325@qq.com
Outgoing Mail (SMTP) server for notifications (optional): greenandtree@163.com
-----------------------------------------------------------------
You have specified the following settings
Database ORACLE_HOME ................ /oracle/ora11/product
Local hostname ................ HZ-NOAH-12-126
Listener ORACLE_HOME ................ /oracle/ora11/product
Listener port number ................ 1158
Database SID ................ ora11g
Email address for notifications ............... 897600325@qq.com
Outgoing Mail (SMTP) server for notifications ............... greenandtree@163.com
-----------------------------------------------------------------
----------------------------------------------------------------------
WARNING : While repository is dropped the database will be put in quiesce mode.
----------------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
May 16, 2012 9:08:14 AM oracle.sysman.emcp.util.EMCALogManager addLogFileInternal
WARNING: Adding log file /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log failed. Messages will not be logged in this file.
May 16, 2012 9:08:14 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log.
May 16, 2012 9:08:15 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: ORA-12541: TNS:no listener
May 16, 2012 9:08:15 AM oracle.sysman.emcp.EMConfig perform
SEVERE:
Database connection through listener failed. Fix the error and run EM Configuration Assistant again.
Some of the possible reasons may be:
1) Listener port 1158 provided is incorrect. Provide the correct port.
2) Listener is not up. Start the Listener.
3) Database service ora11g is not registered with listener. Register the database service.
4) Listener is up on physical host and ORACLE_HOSTNAME environment variable is set to virtual host. Unset ORACLE_HOSTNAME environment variable.
5) Listener is up on virtual host. Set environment variable ORACLE_HOSTNAME=<virtual host>.
6) /etc/hosts does not have correct entry for hostname.
Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
Could not complete the configuration. Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
#1
/oracle/ora11/product/oc4j/j2ee/
--这里是你的Oracle安装目录
OC4J_DBConsole_HZ-NOAH-12-126_ora11g
--这里是一个文件夹
HZ-NOAH-12-126
--这里一般是你主机的名字
ora11g
--这里是你数据库的SID
以上都对了就能进去了。
--这里是你的Oracle安装目录
OC4J_DBConsole_HZ-NOAH-12-126_ora11g
--这里是一个文件夹
HZ-NOAH-12-126
--这里一般是你主机的名字
ora11g
--这里是你数据库的SID
以上都对了就能进去了。
#2
是不是安装有问题哦,一般使用向导安装完直接$emctl start dbconsole就起来了,顶多字符编码等问题设置设置~
#3
重建一下
emca -config dbcontrol db -repos recreate
emca -config dbcontrol db -repos recreate
#4
重启后报错如下:
[root@HZ-NOAH-12-126 ~]# su - oracle
[oracle@HZ-NOAH-12-126 ~]$ emca -config dbcontrol db -repos recreate
STARTED EMCA at May 16, 2012 9:04:54 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database SID: ora11g
Listener port number: 1158
Listener ORACLE_HOME [ /oracle/ora11/product ]: /oracle/ora11/product
Password for SYS user:
Password for DBSNMP user:
May 16, 2012 9:07:31 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
WARNING: ORA-28000: the account is locked
Password for SYSMAN user:
Email address for notifications (optional): 897600325@qq.com
Outgoing Mail (SMTP) server for notifications (optional): greenandtree@163.com
-----------------------------------------------------------------
You have specified the following settings
Database ORACLE_HOME ................ /oracle/ora11/product
Local hostname ................ HZ-NOAH-12-126
Listener ORACLE_HOME ................ /oracle/ora11/product
Listener port number ................ 1158
Database SID ................ ora11g
Email address for notifications ............... 897600325@qq.com
Outgoing Mail (SMTP) server for notifications ............... greenandtree@163.com
-----------------------------------------------------------------
----------------------------------------------------------------------
WARNING : While repository is dropped the database will be put in quiesce mode.
----------------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
May 16, 2012 9:08:14 AM oracle.sysman.emcp.util.EMCALogManager addLogFileInternal
WARNING: Adding log file /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log failed. Messages will not be logged in this file.
May 16, 2012 9:08:14 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log.
May 16, 2012 9:08:15 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: ORA-12541: TNS:no listener
May 16, 2012 9:08:15 AM oracle.sysman.emcp.EMConfig perform
SEVERE:
Database connection through listener failed. Fix the error and run EM Configuration Assistant again.
Some of the possible reasons may be:
1) Listener port 1158 provided is incorrect. Provide the correct port.
2) Listener is not up. Start the Listener.
3) Database service ora11g is not registered with listener. Register the database service.
4) Listener is up on physical host and ORACLE_HOSTNAME environment variable is set to virtual host. Unset ORACLE_HOSTNAME environment variable.
5) Listener is up on virtual host. Set environment variable ORACLE_HOSTNAME=<virtual host>.
6) /etc/hosts does not have correct entry for hostname.
Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
Could not complete the configuration. Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
[root@HZ-NOAH-12-126 ~]# su - oracle
[oracle@HZ-NOAH-12-126 ~]$ emca -config dbcontrol db -repos recreate
STARTED EMCA at May 16, 2012 9:04:54 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database SID: ora11g
Listener port number: 1158
Listener ORACLE_HOME [ /oracle/ora11/product ]: /oracle/ora11/product
Password for SYS user:
Password for DBSNMP user:
May 16, 2012 9:07:31 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineLoacly
WARNING: ORA-28000: the account is locked
Password for SYSMAN user:
Email address for notifications (optional): 897600325@qq.com
Outgoing Mail (SMTP) server for notifications (optional): greenandtree@163.com
-----------------------------------------------------------------
You have specified the following settings
Database ORACLE_HOME ................ /oracle/ora11/product
Local hostname ................ HZ-NOAH-12-126
Listener ORACLE_HOME ................ /oracle/ora11/product
Listener port number ................ 1158
Database SID ................ ora11g
Email address for notifications ............... 897600325@qq.com
Outgoing Mail (SMTP) server for notifications ............... greenandtree@163.com
-----------------------------------------------------------------
----------------------------------------------------------------------
WARNING : While repository is dropped the database will be put in quiesce mode.
----------------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: y
May 16, 2012 9:08:14 AM oracle.sysman.emcp.util.EMCALogManager addLogFileInternal
WARNING: Adding log file /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log failed. Messages will not be logged in this file.
May 16, 2012 9:08:14 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log.
May 16, 2012 9:08:15 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: ORA-12541: TNS:no listener
May 16, 2012 9:08:15 AM oracle.sysman.emcp.EMConfig perform
SEVERE:
Database connection through listener failed. Fix the error and run EM Configuration Assistant again.
Some of the possible reasons may be:
1) Listener port 1158 provided is incorrect. Provide the correct port.
2) Listener is not up. Start the Listener.
3) Database service ora11g is not registered with listener. Register the database service.
4) Listener is up on physical host and ORACLE_HOSTNAME environment variable is set to virtual host. Unset ORACLE_HOSTNAME environment variable.
5) Listener is up on virtual host. Set environment variable ORACLE_HOSTNAME=<virtual host>.
6) /etc/hosts does not have correct entry for hostname.
Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.
Could not complete the configuration. Refer to the log file at /oracle/ora11/cfgtoollogs/emca/ora11g/emca_2012_05_16_09_08_14.log for more details.