How to Install and Deinstall DBconsole
Table of Contents
|
Introduction
This guide explains how to install and deinstall DBconsole on a 10g database for both RAC and Non-RAC environments.Useful Information
- Metalink articles 278100.1 and 395162.1
- Read the Know Issues section below.
Step-By-Step - DBconsole RAC Uninstall
WARNING: The uninstall process will Quiesce the database. Do not run on a live system1. Ensure you have the following information before continuing.
2. Log onto any node in the cluster.
- Database unique name
- Listener port number
- Password for SYS user
- Password for SYSMAN user
3. Set-up your environment
4. Deconfigure dbconsole and drop the repository
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- emca -deconfig dbcontrol db -repos drop -cluster
Step-By-Step - DBConsole RAC Install
1. Ensure you have the following information before continuing.2. Log onto any node in the cluster.
- The Database unique name
- The Listener port number
- The Cluster name
- The Password for SYS user
- The Password for DBSNMP user
- The Password for SYSMAN user
- The Email address for notifications (optional)
- The Outgoing Mail (SMTP) server for notifications (optional)
- The ASM ORACLE_HOME e.g. /u01/app/asm/product/10.2.0
- The ASM port e.g. 1521
- The ASM user role e.g. SYSDBA
- The ASM username e.g. SYS
- The ASM user password
3. Set-up your environment
4. Install database control
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- emca -config dbcontrol db -repos create -cluster
Step-By-Step - DBconsole Non-RAC Uninstall
WARNING: The uninstall process will Quiesce the database. Do not run on a live system1. Ensure you have the following mandatory information before starting.
2. Log onto the host.
- The Database SID
- The Listener port number
- The Password for SYS user
- The Password for SYSMAN user
3. Set-up your environment.
3. Uninstall dbconsole
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- cd $ORACLE_HOME/bin
- ./emca -deconfig dbcontrol db -repos drop
Step-By-Step - DBconsole Non-RAC Install
1. Ensure you have the following mandatory information before starting.2. Log onto the host.
- The Database SID
- The Listener port number
- The Password for SYS user
- The Password for DBSNMP user
- The Password for SYSMAN user
- The ASM ORACLE_HOME. e.g. /u01/app/asm/product/10.2.0
- The ASM SID
- The ASM Listener port. e.g. 1521
- The ASM user role. e.g. SYSDBA
- The ASM SYS username
- The ASM SYS user password
3. Set-up your environment.
4. Install *dbconsole*
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- cd $ORACLE_HOME/bin
- ./emca -config dbcontrol db -repos create
Step-By-Step - Manual Uninstall
NOTE - This is not supported by Oracle and has been tried on a 10.2..0.4 database onlyNOTE - There may be other steps you need to take on your environment that have not been documented here
NOTE - Use with caution
Using the dbconsole uninstall on 10g can be problematic due to a rather unnecessary (in my opion) db quiesce that is run prior to dropping the SYSMAN user. The effect of this quiesce is to stall the database whilst it takes place. This stall can cause chaos in an active database environment. I am not quite sure why Oracle had this quiesce in the uninstall, especially given you are about to drop the SYSMAN user. In 11g, I notice the quiesce has gone.
The following steps explain how to perform a manual uninstall of dbconsole.
1. Drop any dbconsole related public synonyms
2. Drop any dbconsole related roles.
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- DROP PUBLIC SYNONYM SETEMVIEWUSERCONTEXT;
- DROP PUBLIC SYNONYM MGMT_TARGET_BLACKOUTS;
3. Drop the SYSMAN user.
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- DROP ROLE MGMT_USER;
4. Drop the MGMT_VIEW user.
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- DROP USER SYSMAN CASACDE;
- . oraenv
- ORACLE_SID = [SID] ? enter sid
- DROP USER MGMT_VIEW CASACDE;
Step-By-Step - Reconfigure Port Number
1. To reconfigure the HTTP port number run the following command.
- For a RAC environment…
- emca -reconfig ports -cluster -DBCONTROL_HTTP_PORT 8888
- For a Non-RAC environment…
- emca -reconfig ports -DBCONTROL_HTTP_PORT 8888
Useful Commands
Starting dbconsole
1. Log onto the database server.
- cd $ORACLE_HOME/bin
- ./emctl start dbconsole
Stopping dbconsole
1. Log onto the database server.
- cd $ORACLE_HOME/bin
- ./emctl stop dbconsole
Checking dbconsole
1. Log onto the database server.
- cd $ORACLE_HOME/bin
- ./emctl status dbconsole
Changing the SYSMAN password (10.2.0.4 onwards)
1. Log onto the database server and stop dbconsole2. Change the sysman password
- ./emctl stop dbconsole
3. Edit the file emoms.properties
- sqlplus '/ as sysdba'
- SQL> alter user sysman identified by
4. Start dbconsole
- cd $ORACLE_HOME/host_sid/sysman/config
- vi emoms.properties
- Search for the line beginning with oracle.sysman.eml.mntr.emdRepPwd=
- Replace the encrypted value by the new password value
- Search for the line: oracle.sysman.eml.mntr.emdRepPwdEncrypted=TRUE
- Replace TRUE by FALSE
5. Check that the password has been encrypted
- ./emctl start dbconsole
- vi emoms.properties
- Search for the line beginning with: oracle.sysman.eml.mntr.emdRepPwd=
- Search for the line beginning with: oracle.sysman.eml.mntr.emdRepPwdEncrypted=
- Check that the value is TRUE
Changing the SYSMAN password (prior to 10.2.0.4)
1. Log onto the database server
- ./emctl stop dbconsole
- sqlplus '/ as sysdba'
- SQL> alter user sysman identified by
- ./emctl setpasswd dbconsole
- Please enter new repository password:
- ./emctl start dbconsole
Setting up Email Alerts
This section explains how to set-up and configure email alerts via Grid Control. Please note, for simplicity, these instructions deal with a single notification rule and alert. Users should create or amend the notification rules and alerts to suit their own needs.1. Configure the mail server that dbconsole will use to send emails.
2. Set-up the email addresses that will receive emails from dbconsole
- Click on setup in the top right-hand corner of dbconsole
- Click on Notification Methods in the side bar
- Enter a valid Outgoing Mail (SMTP) Server
- Enter a suitable description for Identify Sender As
- Enter a suitable email address for Sender's E-mail Address
- Click on Test Mail Servers
- Check to see if an email has been received in the Sender's E-mail Address inbox.
- Click apply if satisfied with the test.
3. Define a schedule for when you wish to receive alerts.
- Click on preferences in the top right-hand corner of dbconsole
- Enter a valid email recipient in the E-mail Address field.
- Select a suitable Message Format. For SMS messages, this should be set to short
- Ensure the Select tick box is ticked and click Test
- Click Ok
- Click apply if satisfied with the test.
4. Create a notification rules.
- Click on preferences in the top right-hand corner of dbconsole
- Click on schedule in the side bar.
- Click on Edit Schedule Definition
- Select a Rotation Frequency
- Click Edit Existing Schedule
- Set a suitable Start Time and End Time for the schedule.
- In the E-mail Addresses field, enter one of the email addresses defined in section 3 above.
- Select the Days of Week that are applicable to the schedule being created.
- Click Batch Fill-in
- Click Finish
At this point, whenever a metric threshold is triggered, the notification rule will capture the alert and send the alert to the email addresses defined based on the schedule settings.
- Click on preferences in the top right-hand corner of dbconsole
- Click on rules in the side bar.
- Click create
- Enter a Name for the notification rule.
- Enter a Description for the notification rule.
- Select a Target Type. For example, database.
- Ensure Apply rule to all targets of the target type selected is selected.
- Click Next
- Select the availability states to be notified on.
- Click Next
- Select the Severity States to be notified on.
- Use the Arrows to move the Available Metrics into the Selected Metrics box. Any metrics in the Selected Metrics box, will be alerted on.
- Click Next.
- Depending on which metrics were chosen, it may be necessary to define further attributes for the metric.
- When satisfied all additional metric properties have been defined, click Next.
- Ensure the Send Me E-mail tick box is ticked.
- Click Next
- Review the Notification Rule and click Finish
Known Issues
Unsecuring dbconsole on RAC (11.2) fails for the daemon processes
Description
Unsecuring dbconsole works on the node where the console is installed, but on subsquent nodes where the daemon process is running the unsecure fails with the following message You must use emctl unsecure em/iasconsole or agentCause
This is caused by bug 8574044Step-By-Step Fix
The following workaround can be used1. Run the following on the node running the console agent
2. Run the following on the nodes running the daemon process
- cd $ORACLE_HOME/bin
- export ORACLE_UNQNAME=
- ./emctl stop dbconsole
3. Run the following on the node running the console agentRepeat on all nodes running the daemon process
- cd $ORACLE_HOME/bin
- export ORACLE_UNQNAME=
- ./emctl stop dbconsole
- cd $ORACLE_HOME/sysman/config
- mv emoms.properties emoms.properties.original
- cd $ORACLE_HOME/bin
- ./emctl unsecure dbconsole
- cd $ORACLE_HOME/sysman/config
- mv emoms.properties.original emoms.properties
4. Run the following on the nodes running the daemon process run ….
- cd $ORACLE_HOME/bin
- export ORACLE_UNQNAME=
- ./emctl unsecure dbconsole
- ./emctl start dbconsole
- cd $ORACLE_HOME/bin
- export ORACLE_UNQNAME=
- ./emctl start dbconsole
emca Deconfigure and Repos Drop for RAC Fails with Invalid Password/Username
Description
When trying to deconfigure and drop the repository for dbconsole emca reports the following errorCould not connect to SYS/(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=myhost1)(PORT=1521))
(ADDRESS=(PROTOCOL=TCP)
(HOST=myhost2)(PORT=1521))(LOAD_BALANCE=yes))(CONNECT_DATA=(SERVICE_NAME=MYDB))):
ORA-01017: invalid username/password; logon denied (DBD ERROR: OCISessionBegin)
Cause
This is due to an invalid password file on one or all of the RAC nodes.Step-By-Step Fix
1. Log on to each node and run the following command2. Make sure the timestamp for the passowrd file has been updated.
- alter sys identified by password
3. Re-run the emca tool
- cd $ORACLE_HOME/dbs
- ls orapwSID
NOTE
This MUST be done on every node and the SAME password used.
Install Fails with Cannot Deploy State Dirs
The installation fails with a message similar to the followingoracle.sysman.emcp.EMAgentConfig instantiateEMConfigFilesCONFIG:
Failed to deploy state dirsMay PM oracle.sysman.emcp.EMConfig performSEVERE:
Error instantiating EM configuration files
Cause and Fix
This can be caused by a number of issues- Make sure you use the hostname if prompted.
- Ensure that the host file on the server is formatted correctly. E.g. ip address myhost.mydomain.com myhost NOTE It is critical that the FQDN comes before the hostname in the host file.
- Ensure nslookup returns the correct FQDN hostname when entering the IP address and the correct IP Address when entering the hostname
- Ensure the hostname command returns the hostname in the hosts file.
- If the database was cloned or the binaries copied from another server, perform an uninstall of dbconsole first. Do not try to reconfigure
- Ensure you are using the correct JRE version for the version of dbconsole being installed.
No comments:
Post a Comment