# Chapter 1. Getting Started

This chapter describes the tasks you need to perform after installing the Agent Development Kit software. These tasks differ somewhat depending upon whether you are using the software on a UNIX system or a Windows NT system. This chapter discusses the following topics:

- Administrative Tasks on UNIX Systems

- User Tasks for UNIX Systems

- Agent Startup Tasks on UNIX Systems

- Administrative Tasks on Windows NT Systems

- User Tasks on Windows NT Systems

- Agent Startup Tasks on Windows NT Systems

## Administrative Tasks on UNIX Systems

To begin with, perform the following tasks:

1. Set your PATH to point to the BEA Manager executables

All users of the installed BEA Manager products will need to update their PATH environment variable to include the location of the BEA Manager executable files. The following is a C shell example:

    % set path = ( $PATH installation_directory/bin )

2. Copy the configuration file

Log in as root and copy the BEA Manager configuration file `beamgr.conf` from `installation_directory``/etc` to the `/etc` directory.

    %su
    Password:
    # cp installation_directory/etc/beamgr.conf /etc

3. Specify the destination for traps, if desired

The default destination for SNMP trap notifications is `localhost`. If you want to set a different target destination for SNMP traps, use your favorite text editor to modify the BEA Manager configuration file (`beamgr.conf`) TRAP_HOST entry. The TRAP_HOST entry is used to specify the host name of the target destination machine for SNMP trap notifications, and the port number and community name to use in sending traps. For more information refer to the "Configuration Files" chapter in the Agent Integrator Reference Manual.

4. Specify non-default SNMP communities and SMUX password, if desired

   By default, BEA Manager agents (such as the Agent Integrator or `tux_snmpd` when running as an SNMP agent) use `public` as the read-only community and `iview` as the read-write community when communicating with SNMP managers. If you want to specify different community names to be used by BEA Manager SNMP agents, this is specified in the BEA Manager passwords file. The passwords file can also be used to specify a password to be used by Agent Integrator for authenticating connection requests from SMUX subagents. To set up the passwords file, do the following:

   1. Copy the BEA Manager passwords file (`beamgr_snmpd.conf`) from the `installation_directory``/etc` to the `/etc` directory and make the copy readable and writable only by root. For example:

       # cp installation_directory/etc/beamgr_snmpd.conf /etc
       # chmod 600 /etc/beamgr_snmpd.conf

   2. Now you can edit the copied file to update your SNMP communities. The keywords in this file are:

   - SMUX_PASSWD

   - COMMUNITY_RO

   - COMMUNITY_RW

   For more information refer to the "Configuration Files" chapter in the Agent Integrator Reference Manual.

5. Advertise services if you need to use non-standard ports

   By default, BEA Manager agents assume the following port numbers as specified by SNMP and SMUX standards:

       snmp         161/udp
       snmp-trap    162/udp
       smux         199/tcp

   The default port assignments may be sufficient for your needs. If necessary, you can define these services on other ports, or use the appropriate command-line options when starting BEA Manager agents to assign them to non-default ports.

   1. To modify or define the services, determine if the NIS is running. You can use the `ypwhich` command to determine if an NIS server or map master is available. For example:

       % ypwhich
       zort.kremvax.com

   2. If an NIS server is available, you can use the `ypcat` command to determine if the services are available.

       % ypcat services | grep snmp
       snmp-trap    162/udp    snmptrap
       snmp         161/udp

   3. If an NIS server is not available and services are provided on the local host, you can examine the `/etc/services` file instead.

       % cat /etc/services | grep snmp
       snmp-trap    162/udp    snmptrap
       snmp         161/udp

   Refer to your UNIX system documentation, or consult your UNIX system administrator, for instructions specific to your UNIX platform to establish the SNMP services if necessary.

## User Tasks for UNIX Systems

All users of the Agent Development Kit have to set certain environment variables for the product to function properly. In addition to the environment variables shared with other BEA Manager products, the following environment variable needs to be set:

RELEASE_ROOT
  Must contain the location of the installed files.

``

  >     % setenv RELEASE_ROOT /net/tuxedo

## Agent Startup Tasks on UNIX Systems

Before running the Agent Integrator or other agents supplied with the Agent Development Kit, or an agent built using the Agent Development Kit, perform the following tasks:

1. Modify the BEA Manager configuration file entries, if desired

If you are using the `unix_snmpd` subagent, you may want to modify the following fields in the BEA Manager configuration file (`beamgr.conf`) after copying it to `/etc`:

- SYS_DESCR

- SYS_INSTALL

- SYS_CONTACT

- SYS_NAME

- SYS_LOCATION

- SYS_SERVICES

These entries correspond to MIB objects in the `beaSystem` MIB group supported by the `unix_snmpd` subagent.

Refer to the "Configuration Files" chapter in the Agent Integrator Reference Manual for details on these entries.

2. Start the agents

Now, log in as root and start the agents in the following order:

    % su
    Password:
    # snmp_integrator
    # unix_snmpd

## Administrative Tasks on Windows NT Systems

After installing the Agent Development Kit software, perform the following tasks:

1. Install the BEA Manager configuration file

Copy the BEA Manager configuration file (`beamgr.conf`):

    md c:\etc
    copy installation-directory\etc\beamgr.conf c:\etc

2. Specify the destination for traps, if desired

The default destination for SNMP trap notifications is `localhost`. If you want to set a different target destination for SNMP traps, use your favorite text editor to modify the BEA Manager configuration file (`beamgr.conf`) TRAP_HOST entry. The TRAP_HOST entry is used to specify the host name of the target destination machine for SNMP trap notifications, and the port number and community name to use in sending traps. For more information refer to the "Configuration Files" chapter in the Agent Integrator Reference Manual.

3. Specify non-default SNMP communities and SMUX password (if desired)

   By default, BEA Manager agents (such as the Agent Integrator or `tux_snmpd` when running as an SNMP agent) use `public` as the read-only community and `iview` as the write-read community when communicating with SNMP managers. If you want to specify different community names to be used by BEA Manager SNMP agents, this is specified in the BEA Manager passwords file. The passwords file can also be used to specify a password to be used by Agent Integrator for authenticating connection requests from SMUX subagents. To set up the passwords file, do the following:

   1. Copy the BEA Manager passwords file (`beamgr_snmpd.conf`) to `c:\etc`. For example:

       copy installation-directory\etc\beamgr_snmpd.conf c:\etc

   2. Now you can modify the SNMP communities in this file. The keywords used in this file are:

   - SMUX_PASSWD

   - COMMUNITY_RO

   - COMMUNITY_RW

   For more information refer to the "Configuration Files" chapter in the Agent Integrator Reference Manual.

4. Advertise services if you need to use non-standard ports

   By default, BEA Manager agents assume the following port numbers as specified by SNMP and SMUX standards:

       snmp         161/udp
       snmp-trap    162/udp
       smux         199/tcp

   The default port assignments may be sufficient for your needs. If necessary, you can define these services on other ports, or use the appropriate command-line options when starting BEA Manager agents to assign them to non-default ports.

   To modify or define the service locally, add the appropriate lines in the NT-root-directory`\system32\drivers\etc\services` file. You may wish to consult your system administrator.

## User Tasks on Windows NT Systems

All users of the Agent Development Kit have to set certain environment variables for the product to function properly.

RELEASE_ROOT
  Must contain the location of the installed files.

PATH
  Should include the location of the Agent Development Kit executable files.

For example:

>     set RELEASE_ROOT=c:\net\tuxedo
>     set PATH=%RELEASE_ROOT%\bin:%PATH%

## Agent Startup Tasks on Windows NT Systems

Before running the Agent Integrator or other agents supplied with the Agent Development Kit, or any agents built using the Agent Development Kit, carry out the following tasks:

1. Modify entries in the configuration file (if desired)

Before running any agents built with the Agent Development Kit, you may need to modify the following fields in the BEA Manager configuration file (`beamgr.conf`):

- SYS_DESCR

- SYS_INSTALL

- SYS_CONTACT

- SYS_NAME

- SYS_LOCATION

- SYS_SERVICES

These entries correspond to MIB objects in the `beaSystem` MIB group supported by the `nt_snmpd` subagent.

Refer to the "Configuration Files" chapter of the Agent Integrator Reference Manual for details on these entries.

2. Start the agents from the Windows NT service panel

The Agent Integrator and agents are installed as Windows NT services.

1. The Agent Integrator is installed as a Windows NT service (`snmp_integrator`).

2. A system agent is installed as a Windows NT service (`nt_snmpd`).

For starting agents generated using the Agent Development Kit, refer to the next section, "Executing SNMP Agents Generated by the Agent Development Kit."

The Integrator and agents must be started from the Services control panel. Expose the Windows Taskbar and select the Start Button. Select Settings from the menu, and open the Control Panel. Double-click on the Services applet. From the Taskbar, select StartSettingsControl PanelServices.

Locate each of the installed services. Agent Integrator (`snmp_integrator`) must be started prior to the subagents (but after any NON_SMUX_PEERs).

> Figure 1-1 Selecting Services from the Control Panel

Locate the installed service (`tux_snmpd`) and select Start to start it. There may be a short delay as the service is initiated.

> Figure 1-2 Starting a Selected Service

If a SMUX master agent (e.g., `snmp_integrator`) is not running, the user must provide `-s` as a start-up parameter before selecting Start.

### Executing SNMP Agents Generated by the Agent Development Kit

On a Windows NT system, the SNMP agents generated by the Agent Development Kit need to be installed as a service. To install an agent as a service (e.g., to install `my_snmpd.exe`), enter the command:

>     instsrv.exe my_snmpd absolute-path\my_snmpd.exe

Once this command is executed, start the `my_snmpd` service from the Service Control Panel. From the Taskbar, select StartSettingsControl PanelServices.