Oracle DBA Tips Corner |
|
Installing Grid Control Management Agent (10.2.0.5)
by Jeff Hunter, Sr. Database Administrator
Contents
Overview
Oracle Management Agent is one of the integral components of the Enterprise Manager
Grid Control architecture. Management Agent will discover, monitor and administer all
targets on their hosts, including databases, application servers, other software,
and aspects of the hosts themselves. Management Agent communicates with the
monitored targets, collects information about their health and performances,
transports that information to Oracle Management Service (OMS), which in turn
stores the collected details in the central repository created in the Oracle database.
For the purpose of this article, the Oracle Management Agent (10.2.0.5) will be installed
on a database server node named vmlinux1.idevelopment.info which hosts a
single Oracle 10g database named TESTDB1. The Management Agent will be
registered with a central Grid Control environment running on the node
oemprod.idevelopment.info. The method used in this article to
install the Oracle Management Agent will be:
The following is a conceptual view of what the configuration will look like by the
end of this document:
Further Reading
Enterprise Manager 10g Grid Control Release 2 (10.2.0.1)
To de-configure Database Control for a single instance database, run the following
command:
This article provides one approach (out of several available)
used to install and configure the Oracle Management Agent (10.2.0.5) on
an Oracle database server node running the Red Hat Enterprise Linux 5 operating system.
Installing the Management Agent will be done using the GUI-based
Oracle Universal Installer (OUI) interactive method -
"Installing Management Agent Using Oracle Universal Installer (OUI)".
The OUI is a GUI-based application and therefore requires the use of an X Server.
This guide assumes you have a working Oracle Enterprise Manager 10g
Grid Control Release 5 environment in place and running.
For a comprehensive guide on how to install Oracle Enterprise Manager 10g
Grid Control Release 5 (10.2.0.5) on the Red Hat Enterprise Linux 5
operating system, please see my article
"Installing Grid Control (10.2.0.5) on RHEL 5 with 11g Database Repository".
Installing Management Agent Using OUI
Grid Control (and the Management Agent described in this article) is a large,
bloated, and overly complex web application which,
needless to say, is riddled with a considerable number of bugs.
Consequently, this article should not be considered
a substitute for completely reading and understanding the official
installation guide and release notes from Oracle (although, in many cases, the
documentation is as poorly written as the OEM application itself). Pay considerable attention
to the prerequisites for your environment before attempting the install.
The following links can be used to download the official installation
guides and release notes for Oracle Enterprise Manager 10g:
Enterprise Manager 10g Grid Control Release 5 (10.2.0.5)
Enterprise Manager Grid Control Quick Installation Guide for Linux x86
Enterprise Manager Release Notes for Linux x86
Oracle Management Agent
Enterprise Manager Grid Control Release Notes for Linux and Microsoft Windows
10g R2 Management Agent Deployment Best Practices
If your existing Oracle database is configured with Database Control, then
ensure that you de-configure it before you begin the installation of Management Agent.
[oracle@vmlinux1 ~]$ echo $ORACLE_SID
TESTDB1
[oracle@vmlinux1 ~]$ $ORACLE_HOME/bin/emca -deconfig dbcontrol db -repos drop
STARTED EMCA at May 11, 2009 7:46:16 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: TESTDB1
Listener port number: 1521
Password for SYS user: xxxxxxxx
Password for SYSMAN user: xxxxxxxx
Do you wish to continue? [yes(Y)/no(N)]: y
May 11, 2009 7:46:27 PM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/product/10.2.0/db_1/cfgtoollogs/emca/TESTDB1/emca_2009-05-11_07-46-16-PM.log.
May 11, 2009 7:46:28 PM oracle.sysman.emcp.util.DBControlUtil stopOMS
INFO: Stopping Database Control (this may take a while) ...
May 11, 2009 7:46:38 PM oracle.sysman.emcp.EMReposConfig dropRepository
INFO: Dropping the EM repository (this may take a while) ...
May 11, 2009 7:47:37 PM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully dropped
Enterprise Manager configuration completed successfully
FINISHED EMCA at May 11, 2009 7:47:38 PM
|
NLS_LANG Environment Variable Requirements
If your operating system is Linux, then ensure the NLS_LANG environment variable (or ORA_NLS10 in my case) is set with a value that is compatible with the operating system default locale setting and the database character set.In this article, I set the ORA_NLS10 environment variable in the .bash_profile log in script for the oracle UNIX account as follows:
export ORA_NLS10=$ORACLE_HOME/nls/data
Grant EXECUTE Privilege on DBMS_RANDOM to DBSNMP
SQL> grant execute on dbms_random to dbsnmp; Grant succeeded.
Create Oratab Entries
Prepare the Enterprise Manager 10g Grid Control environment by creating the following entry in the /etc/oratab file:[oracle@vmlinux1 ~]$ echo agent10g:/u01/app/oracle/product/agent10g:N >> /etc/oratabVerify /etc/oratab entries:[oracle@vmlinux1 ~]$ cat /etc/oratab | grep '^[^#]' TESTDB1:/u01/app/oracle/product/10.2.0/db_1:Y agent10g:/u01/app/oracle/product/agent10g:N
![]()
Oracle Real Application Clusters (RAC)
If the target database is clustered using Oracle RAC, create the new oratab entry on all nodes in the cluster:
[oracle@thing1 ~]$ echo agent10g:/u01/app/oracle/product/agent10g:N >> /etc/oratab [oracle@thing2 ~]$ echo agent10g:/u01/app/oracle/product/agent10g:N >> /etc/oratab
Install Management Agent (10.2.0.5)
Download Oracle Management Agent (10.2.0.5)
Oracle offers a development and testing license free of charge. No support, however,
is provided and the license does not permit production use.
A full description of the license agreement is available on OTN.
After downloading the Management Agent for your platform, (as the "oracle" user account),
extract the archived file to a temporary directory. In this example,
I will use /home/oracle/software/management_agent/10.2.0.5/linux_x86.
After extracting the Management Agent software, verify you are logged in as the
oracle user account, set your environment for the Management Agent
(using agent10g from /etc/oratab),
start your "X" emulation software (if required) and run the Oracle Universal Installer.
Oracle Real Application Clusters (RAC)
If the target database is clustered using Oracle RAC, verify
remote access / user equivalence before running the
Oracle Universal Installer:
Download and install the Oracle Management Agent (10.2.0.5) for Linux
to the database server vmlinux1.
Depending on the O/S platform (Linux x86 for this example), download the appropriate
Oracle Management Agent (10.2.0.5) from the Oracle Technology Network (OTN).
If you do not currently have an account with Oracle OTN, you
will need to create one. This is a FREE account!
Mass Deployment Agent Software from Oracle
[oracle@vmlinux1 ~]$ cd /home/oracle/software/management_agent/10.2.0.5/linux_x86
[oracle@vmlinux1 linux_x86]$ unzip Linux_Grid_Control_agent_download_10_2_0_5_0.zip
Install Management Agent
[oracle@thing1 ~]$ ssh thing1 "date;hostname"
Wed Oct 28 13:44:53 EDT 2009
thing1
[oracle@thing1 ~]$ ssh thing2 "date;hostname"
Wed Oct 28 13:45:36 EDT 2009
thing2
[oracle@vmlinux1 ~]$ . oraenv ORACLE_SID = [TESTDB1] ? agent10g [oracle@vmlinux1 ~]$ cd /home/oracle/software/management_agent/10.2.0.5/linux_x86/linux/agent [oracle@vmlinux1 linux_x86]$ env | egrep "ORACLE_|LD_LIBRARY|NLS|TNS_|HOSTNAME" | sort HOSTNAME=vmlinux1.idevelopment.info LD_LIBRARY_PATH=/u01/app/oracle/product/agent10g/lib:/lib:/usr/lib:/usr/local/lib NLS_DATE_FORMAT=DD-MON-YYYY HH24:MI:SS ORACLE_BASE=/u01/app/oracle ORACLE_HOME=/u01/app/oracle/product/agent10g ORACLE_PATH=/u01/app/oracle/common/oracle/sql:.:/u01/app/oracle/product/10.2.0/db_1/rdbms/admin ORACLE_SID=agent10g ORACLE_TERM=xterm ORA_NLS10=/u01/app/oracle/product/10.2.0/db_1/nls/data TNS_ADMIN=/u01/app/oracle/product/10.2.0/db_1/network/admin [oracle@vmlinux1 linux_x86]$ export DISPLAY=vmlinux1:0 [oracle@vmlinux1 linux_x86]$ ./runInstaller
Specify Installation Type
In the "Specify Installation Type" window, select the forth option (the default and only option available) which is to perform a "Additional Management Agent" install.
Specify Installation Location
Specify the "Parent Directory" that will be used to install the Management Agent". In this example, I will use "/u01/app/oracle/product" as the Parent Directory, however, the actual directory that will be created is "/u01/app/oracle/product/agent10g".
My Oracle Support
(Optional) Specify an email address and My Oracle Support login credentials.
Product-Specific Prerequisite Checks
The Prerequisite check screen will appear and identify possible deficiencies in kernel settings, software packages needed, host configuration, or space available. During the installation of Oracle Management Agent, no deficiencies should occur.
There is one particular exception and that is if you receive the warning:
Checking for the Hostname...If you receive this warning, it is safe to ignore. Acknowledge the warning by clicking the checkbox and continuing the installation.
Check complete. The overall result of this check is: Failed <<<<
Problem: The host name in /etc/hosts is not proper.
Specify Oracle Management Service Location
Enter the host name of the Oracle Management Service (OMS) location. When specifying the host name, use the fully qualified host name (including domain). Also, do not include the protocol when entering the host name (that is, http:// or https://). The default port (4889) is automatically entered in the "Management Service Port" field. For the purpose of this example, the default port will be used.
Specify Agent Registration Password
If the OMS is found to be running in a secure mode, the "Specify Agent Registration Password" screen appears. You must provide the correct password to enable communications between the new Management Agent and the Sockets Layer (SSL)-enabled OMS.
Summary Screen
This screen displays a summary of the options that you have selected during the installation process. Verify that the Source and Oracle Home values are correct and click the "Install" button.
Execute Configuration Scripts
After the install and link phase, the Oracle Universal Installer will present the "Execute Configuration Scripts" dialog specifying that the /u01/app/oracle/product/agent10g/root.sh script be run as the root UNIX user account.
If the target database is clustered using Oracle RAC, run the /u01/app/oracle/product/agent10g/root.sh script as the root UNIX user account on all nodes in the cluster.
Configuration Assistants
After running the "root.sh" script and acknowledging the dialog window, the Oracle Universal Installer will start running the three core configuration assistant tasks. This is a crucial step in the installation process as it performs the patching required for Management Agent 10.2.0.5 and also automatically configures the discovered targets with the Oracle Management Service (OMS).
End of Installation
After successfully installing and configuring Oracle Management Agent, the Oracle Universal Installer will present the "End of Installation" screen.
SQL> alter user dbsnmp account unlock; User altered.
Configure New Database Instance Target in Grid Control Console
- Login to the Oracle Grid Control Console. Note the one configuration error (
) under the "All Targets Alerts" section:
![]()
- Click on the "Targets" tab and scroll down through the list of hosts to the entry for the hostname you recently installed (vmlinux1). If the link doesn't appear, click the refresh button periodically until the host appears.
![]()
- Once the link for the host appears, click on the link and proceed to the "Targets" link. Configure the target database instance by selecting the $ORACLE_SID.$DOMAIN_NAME entry:
![]()
- From the target database page, click the "Configure" button.
![]()
- Enter the password for the DBSNMP user on the target database and click on the "Test Connection" button to ensure the database user DBSNMP is correctly configured for the target database being added. If, as the figure below shows, the test is successful, click "Next".
![]()
- On Screen 5 of 5, click the "Submit" button to configure the target database being added. After several seconds, you should see the results screen indicating the configuration for the database has been successfully updated.
![]()
About the Author
All articles, scripts and material located at the Internet address of http://www.idevelopment.info is the copyright of Jeffrey M. Hunter
and is protected under copyright laws of the United States. This document may not be hosted on any other site without my express,
prior, written permission. Application to host any of the material elsewhere can be made by contacting me at jhunter@idevelopment.info.
I have made every effort and taken great care in making sure that the material included on my web site is technically accurate,
but I disclaim any and all responsibility for any loss, damage or destruction of data or any other property which may arise from
relying on it. I will in no case be liable for any monetary damages arising from such loss, damage or destruction.
Jeffrey Hunter is an Oracle Certified Professional, Java Development Certified Professional, Author,
and an Oracle ACE.
Jeff currently works as a Senior Database Administrator for
The DBA Zone, Inc. located in Pittsburgh, Pennsylvania.
His work includes advanced performance tuning, Java and PL/SQL programming, capacity
planning, database security, and physical / logical database design in a UNIX,
Linux, and Windows server environment. Jeff's other interests include mathematical
encryption theory, programming language processors (compilers and interpreters)
in Java and C, LDAP, writing web-based database administration tools, and of
course Linux. He has been a Sr. Database Administrator and Software Engineer
for over 16 years and maintains his own website site at:
http://www.iDevelopment.info.
Jeff graduated from Stanislaus State University in Turlock,
California, with a Bachelor's degree in Computer Science.
Friday, 30-Oct-2009 13:36:56 EDT
Page Count: 10934