How To Install The Grid Control 10.2.0.4 Agent on Solaris Sparc

Background & Overview

This document details how to install the Grid Control Agent 10.2.0.4 onto any 10g or 9i database host running on Solaris.

Assumptions & Pre-Requisites

The following assumptions and pre-requisites are assumed:-

  • The NFS mount point /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download exists on the server you intend to install the Grid Control agent.
  • A Grid Control repository has been built according the documentation listed here.
  • The Agent Download directory has been configured as detailed in the Grid Control Config Guide

Useful Information

  • Read the Known Issues section below.
  • The install for a VCS cluster uses a staticports.ini file. This allows the port number for the agent to be defined at install time. This is required if installing more than one agent on a host, as each agent must have a different port number.
  • More than one agent on a host is only needed if the host has multiple sets of Oracle binaries that failover independently of each other. If there is only one set of Oracle binaries or the binaries do not failover independent of each other, then the entries in the staticports.ini file should be hashed out using a # or the file removed altogether.
  • It is possible to ignore the statictports.ini steps if only one agent is being installed or if ALL agents on the host are up and running on the host where the agent is being installed.
  • When installing an agent on a VCS cluster, it is important that the agent is installed into a failover mount point.

Step-By-Step Guide

Installing the Agent on a Solaris Standalone Server

1. Log onto the server where the agent is to be installed.

2. Make sure you have the correct oraInst.loc file in place.

3. Unset the variables

  • unset ORACLE_HOME
  • unset ORACLE_BASE
  • unset ORACLE_SID

4. Set the Agent Install and DBSNP Password variable

  • export AGENT_INSTALL_PASSWORD=password
    • NB The password specified above is the current OMS registration password.
  • export DBSNMP_PASSWORD=password
    • NB The password specified above is the current DBSNMP password.
  • export AGENT_HOSTNAME=hostname

5. Copy the agentDownload file to the local host.

  • cd /u01/app/oracle
  • mkdir -p SOFTWARE/agent10g
  • cd SOFTWARE/agent10g
  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/10.2.0.4.0/solaris/agentDownload.solaris agentDownload.solaris
  • chmod 755 agentDownload.solaris
  • ./agentDownload.solaris -b agent_base -m OMS_hostname -r OMS_portno
  • WARNING Be careful to specify the Agent Base and NOT the Agent Install Location.
  • Check the agent10g logfile located /u01/app/oracle/SOFTWARE/agent10g/agentDownload10.2.0.4.0Oui/ErrLog.log

6. Shutdown the Agent

  • cd agent_home/bin
    • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl stop agent

7. Get a UNIX administrator to run root.sh from the agent10g home driectory.

8. Start the Agent

  • cd agent_home/bin
    • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl start agent

9. Follow the Step-By-Step guide Configuring the Agent Install shown below.

Installing the Agent on a Solaris RAC Server

1. Log onto the server where the agent is to be installed.

2. Make sure you have the correct oraInst.loc file in place.

3. Unset the variables

  • unset ORACLE_HOME
  • unset ORACLE_BASE
  • unset ORACLE_SID

4. Set the Agent Install and DBSNP Password variable

  • export AGENT_INSTALL_PASSWORD=password
    • NB The password specified above is the current OMS registration password.
  • export DBSNMP_PASSWORD=password
    • NB The password specified above is the current DBSNMP password.
  • export AGENT_HOSTNAME=hostname

5. Copy the agentDownload file to the local host.

  • cd /u01/app/oracle
  • mkdir -p SOFTWARE/agent10g
  • cd SOFTWARE/agent10g
  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/10.2.0.4.0/solaris/agentDownload.solaris agentDownload.solaris
  • chmod 755 agentDownload.solaris
  • ./agentDownload.solaris -b agent_base -m hostname -r port_no -c node1,node2,node3 -n clustername
    • node1,node2,node3 are the nodes hosting the RAC cluster
    • clustername is the name of the RAC cluster ( to get cluster name run /bin/cemutlo -n
  • WARNING Be careful to specify the Agent Base and NOT the Agent Install Location.
  • Check the agent10g logfile located /u01/app/oracle/SOFTWARE/agent10g/agentDownload10.2.0.4.0Oui/ErrLog.log

6. Shutdown the Agent

  • cd agent_home/bin
    • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl stop agent

7. Get a UNIX administrator to run root.sh from the agent10g home driectory.

8. Start the Agent

  • cd agent_home/bin
    • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl start agent

9. Follow the Step-By-Step guide Configuring the Agent Install shown below.

NOTE You will have to manually install the fix_agent.ksh script on the other nodes in the cluster.

Installing the Agent on a Solaris VCS Cluster

1. Log onto the server where the agent is to be installed.

2. Unset the variables

  • unset ORACLE_HOME
  • unset ORACLE_BASE
  • unset ORACLE_SID

2. Set the Agent Install and DBSNP Password variable

  • export AGENT_INSTALL_PASSWORD=password
    • NB The password specified above is the current OMS registration password.
  • export DBSNMP_PASSWORD=password
    • NB The password specified above is the current DBSNMP password.
  • export AGENT_HOSTNAME=hostname

3. Copy the agentDownload file to the local host.

  • cd /u01/app/oracle
  • mkdir -p SOFTWARE/agent10g
  • cd SOFTWARE/agent10g

4. Copy the VCS oraInst.loc file to the agent10g software directory.

  • cd /u01/app/oracle/SOFTWARE/agent10g
  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/10.2.0.4.0/solaris/custom/VCSoraInst.loc oraInst.loc

5. Copy the staticports.ini file to the agent10g software directory.

  • cd /u01/app/oracle/SOFTWARE/agent10g
  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/10.2.0.4.0/solaris/custom/staticports.ini staticports.ini

6. Update the staticports.ini file with a valid port number.

  • vi staticports.ini
  • %s/port_num/VALID_PORT_NO/g
  • NB If installing multiple agents on the same server for each set of binaries, the port number must be different for each agent. If installing just one agent, then the line can be hashed out.

7. Run the agentDownload script

  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/10.2.0.4.0/solaris/agentDownload.solaris agentDownload.solaris
  • chmod 755 agentDownload.solaris
  • ./agentDownload.solaris -b agent_base -m OMS_hostname -r OMS_portno -i /u01/app/oracle/SOFTWARE/agent10g/oraInst.loc -p /u01/app/oracle/SOFTWARE/agent10g/staticports.ini
  • WARNING Be careful to specify the Agent Base and NOT the Agent Install Location.
  • Check the agent10 logfile located /u01/app/oracle/SOFTWARE/agent10g/agentDownload10.2.0.4.0Oui/ErrLog.log

8. Shutdown the Agent

  • cd agent_home/bin
    • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl stop agent

9. Get a UNIX administrator to run root.sh from the agent10g home driectory.

10. Start the Agent

  • cd agent_home/bin
  • NB The agent home is agent_base/agent10g where agent_base is the value specified in the install step above.
  • ./emctl start agent

10. Follow the Step-By-Step guide Configuring the Agent Install shown below.

Configuring the Agent Install

1. Configure Proxy & Connection Settings for the new agent.

  • In the Grid Control Console click on the Home tab.
  • Click setup in the top right hand corner.
  • Click on Patching Setup in the menu on the left hand side.
  • Click on Proxy & Connection Settings
  • Ensure the radio button for Manual proxy configuration is selected.
  • Ensure the Host is set to proxyhostname.domain
  • Ensure the port is set to portno
  • In the list of Don't proxy for hosts add the new agent hostname to the comma separated list.
  • Ensure the Realm is set to local
  • Ensure the Username is set to proxy username
  • Enter a valid password
  • Click Apply

Known Issues

Error when Trying to Configure a Database

Description

The following error messages may be reported in the emagent.trc when trying to configure a database target or after the agent install has completed.

SQL = " OCIPing"...
LOGIN = dbsnmp/<PW>@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=hostname)(PORT=1521))(CONNECT_DATA=(SID=SIDNAME)))
2009-06-05 12:13:26,567 Thread-432 WARN vpxoci: OCI Error -- ErrorCode(3113): ORA-03113: end-of-file on communication channel

In addition, in the Targets Not Configured page of the the Grid Control front end you will get errors similar to the following

Get dynamic property error,Dynamic Category property error
Compute dynamic property takes too long

Cause

This is a bug reltaing to the way the patched 10.2.0.4 agent interacts with database at version 9.2.0.7 or below.

Fix Step-By-Step

1. Log onto the database having the error and grant sysdba to the dbsnmp user.

  • . oraenv
  • ORACLE_SID = [SID] ? SID
  • sqlplus '/ as sysdba'
  • SQL> grant sysdba to dbsnmp

1. From the Grid Control front end reconfigured the database having the issue.

  • Select the Targets tab.
  • Select the Databases breadcrumb.
  • Select the radio button alongside the database having the issue.
  • Click Configure
  • From the Configure Database Instance: Properties page set the Role field to sysdba
  • Set the Monitor Username field to dbsnmp
  • Ensure you have set a valid password in the Monitor Password field.
  • Click Next
  • Click Submit
  • Click Ok

Error Messages When Starting up Grid Control Agents

Description

The following error messages may be reported when starting grid control agents.

Message Found in Log Metalink Reference Cause
[Thread-5] WARN ias.util getMetricResultUtil.311 - Error getting metric opmn_process_info Error getting metric opmn_process_info rows is null emagentfetchlet.trc 286624.1 Harmless message. Also appears in emagentfetchlet.log
http: snmehl_connect: connect failed to (hostname:1157): Connection refused (error = 146) emdctl.trc N/A If found during the start up of Grid Control, this message is due to the Agent being down.
DEBUG, INFO and WARN messages in emagent.trc log emagent.trc Feature!!
See this log file for error messages emagent.trc emagent.trc Unknown. Feature/Bug
11347 :: Tue May 26 16:37:26 2009::AgentLifeCycle.pm:status agent returned with retCode=1 11347 :: Tue May 26 16:37:49 2009::AgentLifeCycle.pm: Exited loop with retCode=3 emctl.log Feature
2009-05-26 16:37:26,091 Thread-1 WARN http: snmehl_connect: connect failed to (hostname:3872): Connection refused (error = 146) 2009-05-26 16:37:26,091 Thread-1 ERROR main: nmectla_agentctl: Error connecting to https://hostname:3872/emd/main/. Returning status code 1 2009-05-26 16:37:27,363 Thread-1 WARN http: snmehl_connect: connect failed to (hostname:3872): Connection refused (error = 146) 2009-05-26 16:37:27,363 Thread-1 ERROR main: nmectla_agentctl: Error connecting to https://hostname:3872/emd/main/. Returning status code 1 emdctl.trc Feature

Cause

See above.

Fix Step-By-Step

All of these messages can be ignored.

Useful Information

Manual Application of Patch Bundle 1 for Solaris 10.2.0.4 Agent.

The automatic application of patch bundle 1 for the 10.2.0.4 agent should happen automatically if the agent_download directory has been set-up correctly. However, if for any reason the application of patch bundle 1 does not work, the following guide can be used.

NB This is not required if using the amended agent_download script.

  • cd AGENT_HOME/sysman/bin
  • ./emctl stop agent
  • cd /u01/app/oracle/SOFTWARE/agent10g
  • mkdir Recommended
  • cd Recommended
  • cp /net/hostname/u01/app/oracle/GRID/oms10g/sysman/agent_download/Patches/SolarisSPARC/Recommended/Solaris_x64_GridControl_agent_download_10_2_0_2_0.zip Solaris_x64_GridControl_agent_download_10_2_0_2_0.zip
  • unzip Solaris_x64_GridControl_agent_download_10_2_0_2_0.zip
  • cd 8345731
  • export ORACLE_HOME=AGENT_HOME
  • export PERL5LIB=$ORACLE_HOME/perl/lib:$ORACLE_HOME/perl/lib/site_perl
  • export EMSTATE=$ORACLE_HOME
  • export PATH=$PATH:$ORACLE_HOME/OPatch
  • $ORACLE_HOME/perl/bin/perl ./8345731/files/GCAgent/scripts/apply_8345731.pl
  • sh ./8345731/files/GCAgent/scripts/patch8345731_nmo.sh
  • opatch napply -skip_subset -skip_duplicate
  • Get a UNIX administrator to run root.sh from the agent10g home driectory.

Script for Resetting the DBSNMP Password

This script below can be used to configure ther DBSNMP user and the related targets.xml entries after an agent has been installed. Alternatively, it can be performed manually by performing the following commands

NB This is not required if using the amended agent_download script.

1. Log onto the server where the new agent has been installed.
2. For each database where the agent has been installed perform the following steps.

  • Unlock, unexpire and reset the DBSNMP password.
  • . oraenv
  • ORACLE_SID = [oracle] ?
  • sqlplus '/ as sysdba'
  • SQL> alter user dbsnmp identified by current_dbsnmp_password account unlock;

2. Configure the DBSNMP account from the Grid front end.

  • In the Grid Control Console click on the Home tab.
  • Click setup in the top right hand corner.
  • Click on the Agents breadcrumb.
  • Click on the hostname where the agent has been installed.
  • Click on a database that requires configuring. This is donated by the words unconfigured written in red below the database name.
  • From the database instance page, click on configure
  • In the Monitor Password field enter the current DBSNMP password.
  • Click on Test Connection
  • If the Test Connection is successful, click on Next
  • Click Submit
  • Click OK
  • After a period of time, the screen will refresh and the database instance page will be displayed.

#!/bin/ksh
#############################################################################
# Script : setup_dbsnmp.ksh
#
# Date : 4th December 2008
#
# Author : www.oracle-wiki.net
#
# Description : Set-up the DBSNMP user ready for Grid.
#
# Parameters : \$1 - Password for DBSNMP.
#
# History
# V1 Date 4/06/09 Name: MDT Reason:Documented
#
############################################################################
#
# Set-up Variables
#

PASSWORD=$1
export ORAENV_ASK=NO
EMAGENT=$(ps -eo comm | grep emagent)
EMDIR=$(dirname $EMAGENT)
EMCTL=$(echo $EMAGENT | sed 's/emagent/emctl/')

#
#For each DB Loop Around and Configure DBSNMP
#

ps -ef | grep pmon | grep -v grep | awk -F'_' '{print $3}' | while read SID
do
export ORACLE_SID=$SID
. oraenv
sqlplus -s "/ as sysdba" <<EOF
alter user dbsnmp account unlock identified by $PASSWORD
/
exit
EOF

#
#Configure the targets.xml file.
#

TARGET=$(grep $ORACLE_SID ${EMDIR}/../sysman/emd/targets.xml | grep oracle_database | sed 's/.*NAME="\(.*\)".*$/\1/')
$EMCTL config agent credentials ${TARGET}:oracle_database <<EOF
y
dbsnmp
y
$PASSWORD
$PASSWORD
EOF
Done

#
#End Job
#

echo "JOB COMPLETE"
exit 0

staticports.ini file

#staticports.ini Template File
#This file is a template for specifying port numbers at installation time.
#To specify a port number, uncomment the appropriate line (remove #) and
#replace "port_num" with the desired port number.
#You can then launch Oracle Universal Installer with special options to use this file.
#Please refer to Enterprise Manager Grid Control 10gR2 Installation Guide for instructions.
Enterprise Manager Central Agent Port=port_num

VCSoraInst.loc file

#Oracle Installer Location File Location
#Thu Mar 26 10:48:21 GMT 2009
inst_group=dba
inventory_loc=/u01/app/oracle/agent10g/oraInventory

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License