While stopping dbconsole on our production server 10.2.0.1 by emctl it failed to stop with error message "Failed to shutdown DBConsole Gracefully" as below.
$ emctl stop dbconsole
TZ set to Asia/Bangkok
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.
http://localhost.localdomain:1158/em/console/aboutApplication
Stopping Oracle Enterprise Manager 10g Database Control ...
--- Failed to shutdown DBConsole Gracefully ---
failed.
Cause of the Problem
This problem may happen by two reasons as far as I faced.
Cause 01: The server has two active NIC cards and therefore two active IP addresses. DNS resolves to the IP address of eth1 and /etc/hosts lists the IP address of eth0.
In order to see the available NIC cards issue,
$ /sbin/ifconfig -a
Cause 02: Wrong entry inside /etc/hosts.
Inside the /etc/hosts the entry format is,
IP Address fully qualified hostname simple or short hostname Alias
If I have the entry like,
127.0.0.1 localhost.localdomain database
for a machine named hostname database then error will possibly occur.
Solution of the Problem
If the error happened by Cause 01 then,
1)Be sure that nslookup returns the IP address of the primary network adaptor, normally eth0.
2)Set your ORACLE_SID. By export or setenv command you can set environmental variable based on your shell type.
3)Recrate your repository. You can simply do this by two consecutive comamnds.
$emca -deconfig dbcontrol db -repos drop
$emca -config dbcontrol db -repos create
If the error happen by Cause 02 then,
1)Be sure you have correct entry inside /etc/hosts in the following format.
For localhost, the entry should following for host database.
127.0.0.1 database localhost.localdomain localhost
2)Set your ORACLE_SID. By export or setenv command you can set environmental variable based on your shell type.
Like,
export ORACLE_SID=test
where test is your database sid.
3)Recrate your repository. You can simply do this by two consecutive comamnds.
$emca -deconfig dbcontrol db -repos drop
$emca -config dbcontrol db -repos create
No comments:
Post a Comment