Showing posts with label CCMS Agents. Show all posts
Showing posts with label CCMS Agents. Show all posts

Registering the CCMS Agents in Dialog

During the registration of the agent, you enter the required connection data in the central monitoring system. An RFC connection to the agent is automatically created in the central monitoring system during registration. Ensure before the registration that the required configuration files are available.

Features

Depending on the agent, you perform the registration using the following command:

Agent

Registration

SAPCCMSR

sapccmsr –R [pf=]

SAPCM3X

sapcm3x -R [pf=]

SAPCCM4X

sapccm4x –R pf=

With SAPCCM4X, is the full file path of the profile of the monitored instance. In the case of SAPCCMSR/SAPCM3X, it is the full file path of the agent profile (see Profile File of the CCMS Agents).

Activities

You enter the following data during the installation:

· System ID of the central monitoring system

· System IDs of up to four (optional) additional central monitoring systems (see Registering with Multiple Central Monitoring Systems)

· For every central monitoring system, you must also enter a valid SAP user that is used once to create an RFC connection to the agent in the central monitoring system.


This user requires the authorization to execute transactions RZ20/21 (S_RZL_ADM with authorization field ACTVT and value 01) and to enter an RFC destination using transaction SM59 (S_ADMI_FCD with authorization field S_ADMI_FCD and value NADM).

In detail, you enter the following user data (if there is a default value for an entry, this is shown in square brackets. If you want to use this default value, simply press the ENTER key):

· Client

· User name

· Logon language

· Host name of the message server in the central monitoring system

· Indicator of whether load balancing is to be used for logon

· Name of the logon group for logon (in the case of activated load balancing)

· Host name of the application server for logon (in the case of deactivated load balancing)

· System number of the application server for logon (in the case of deactivated load balancing)

· Host and port of the SAProuter in the format /H//S//H (optional, only required in exceptional cases)

· Indicator for a trace (0 = no, 1 = yes)

· Password of the user; the password is only used for the single logon described above and is not stored

· For every central monitoring system, you require the connection data of the gateway (usually the message server of the central monitoring system) with which the CCMS agent communicates as an RFC server.

· Host name of the gateway

· System number of the gateway

If your central monitoring system has a release status of at least SAP Web AS 6.10, the CCMS agent automatically sends alerts to the central monitoring system as an RFC client; as of SAP Web AS 6.20, the agents also automatically report the monitoring attributes.

In both cases, the agent requires an automatically valid logon to the central monitoring system. The user used for this purpose can be purely an RFC user and need not possess any rights at all, as it only calls a precisely defined function module that does not perform any additional authorization checks itself. We recommend that you use the user CSMREG for this purpose (see Structure linkCreating the CSMREG User).

In detail, you enter the following data for this CSMREG user for all central monitoring systems:

· Client

· User name; by default CSMREG

· Logon language

· Host name of the message server in the central monitoring system

· Indicator of whether load balancing is to be used for logon

· Name of the logon group for logon (in the case of activated load balancing)

· Host name of the application server for logon (in the case of deactivated load balancing)

· System number of the application server for logon (in the case of deactivated load balancing)

· Host and port of the SAProuter in the format /H//S//H (optional, only required in exceptional cases)

· Indicator for a trace (0 = no, 1 = yes)

· Password for the user; the password for the CSMREG user is stored in the secure store in an encrypted file called passwd.

If you are registering the CCMS agent on a Microsoft Windows host, the agent is entered and started as a service during the registration. The agent is automatically restarted at every restart. Enter the following information for this:

· Indicator of whether the service is to be automatically started

· Account under which the service is to be started


If you are installing the CCMS agent SAPCCM4X, you must specify a profile path. This profile is usually accessed using a share. You must therefore ensure that the account under which the service for the agent is running has the required network authorizations. You can ensure this by specifying SAPService as the account.

If you have successfully completed the registration, the system displays the message EXITING with code 0; if an error has occurred, the system displays this.

Monitoring Log Files with CCMS Agents

Purpose

One of the functions of CCMS agents is monitoring log files. You can use this log file agent, which is integrated into all agents, to monitor log files for particular search patterns, the last change time, or for their existence. This means that you can search any text files (such as database alert logs or ITS log files) for any text patterns, assign alerts to them, and display the results in the Alert Monitor.

If the agent finds the line for which it is searching, it transfers it to the central monitoring system. You decide the details of the message using entries in the configuration file of the log file agent:

· Color and severity of the alert or the message

· Assigned message

· Assigned analysis method

· Specifications about the position in the alert monitoring tree

In addition, you can monitor the existence and the last change date of particular log files, or display lines that contain a certain search pattern in the Alert Monitor.

Prerequisites

In general, a CCMS agent can only monitor those files that it has permission to read. In the case of the SAPCCM4Xagent, these are the files to which the adm user (UNIX) or the SAPService (Microsoft Windows) has access to, as this agent must always run under this user. In the case of the SAPCCMSR agent, these are the files that the user under which the agent is running has permission to read.

Process Flow

You can use CCMS agents to monitor the following types of log files:

· Log files that are continuously written by the application and are therefore constantly growing (such as the Oracle alert log alert_.log)

With these files, the agent reads newly added entries and saves its last read position.

· Log files that are rewritten under the same name by the application after each restart (such as the dev_w* files of the SAP application server)

With these files, the agent reads newly added entries and saves its last read position. Due to the smaller size of the log file, it automatically recognizes the restart of an application and in this case starts reading from the start of the file again.

· Log files that are created by the application with a new name each time (such as brbackup, brconnect, and so on).

The agent reads newly added entries and saves its last read position. It automatically recognizes the newest log files of a type, so that the current log file can always be monitored.

You can activate log file monitoring in the CCMS Agent configuration file SAPCCMSR.INI. Use the parameter LogFile, to specify a configuration file for each file to be monitored that contains the details of the monitoring (Log File Template). SAPCCMSR.INI can contain multiple entries with the following format:

LogFile
LogFile


For each log file template, you can specify a search criterion for the name of a log file (that can apply to more than one log file) and various text patterns that are to be monitored.

The log file agent also automatically identifies log file templates if they fulfill the following conditions; these log file templates therefore do not need to be specified in SAPCCMSR.INI:

· The names of the templates have the suffix logmon.ini.

· The templates are regular files (for example, not links), not larger than 10 kilobytes in size.

· The templates are stored in the folder \\\saploc\PRFCLOG\logmon
(Microsoft Windows, the folder must be released as a share; see Run Directory and Log Files of the CCMS Agents) or
/usr/sap/tmp/logmon (UNIX).


You can also set the folder in which the log file automatically identifies the log file templates yourself using the parameter LogFileDir in SAPCCMSR.INI (see Configuration File of the CCMS Agent SAPCCMSR.INI).

You can use the optional entry LogFileParam DelTree to specify that subtrees should be deleted in the Alert Monitor if the associated log files no longer exist.

Profile File of the CCMS Agents

Use

You specify a profile file during the registration of a CCMS agent with pf=. This is mandatory for agent SAPCCM4X, and the profile file must be that of the monitored instance. For agents SAPCM3X and SAPCCMSR, on the other hand, the specification of a profile file is optional, and usually not necessary. For these agents, use the profile file to:

· Change the size of the monitoring segment

· Change the working directory of the agent

· Set a virtual name for the host

· Declare the location of the operating system collector SAPOSCOL to the agent; this allows you to start or stop SAPOSCOL for a remote system using the agent

· Activate and deactivate the trace for the monitoring architecture

With the SAPCM3X agent, ensure that you specify the profile of the monitored instance as a profile file if SAP instances with a higher release are also running on the host. Otherwise, data for these systems is also displayed, erroneously.

Structure

The important profile parameters for the agents are:

alert/MONI_SEGM_SIZE

Size of the monitoring segment in the shared memory in bytes (by default, 20.000.000 bytes; see also SAP Note 135503)

DIR_PERF

Working directory of the CCMS agent and SAPOSCOL (see Installing and Registering CCMS Agents)

exe/saposcol

Complete path of SAPOSCOL

alert/TRACE

Trace for monitoring architecture data; set this trace only if expressly told to do so by Support; the default value is 1 (trace deactivated)

SAPLOCALHOST

Virtual host name used for addressing the local host of the agent

In the context of high availability solutions, there can be various hosts, one of which is used as a replacement for emergencies or maintenance periods, but which should be externally addressed by the same name: only one of these should ever be in operation at any time.

If a CCMS agent is installed on each of these hosts, the context name of the monitoring data (which also contains the name of the host) should be identical, irrespective of which host is currently running. Ensure this by setting an identical profile parameter SAPLOCALHOST in the profile file of the CCMS agent. Take this into account with the SAPCCMSR agent in particular, as the SAPCCM4X agent uses the profile parameters of the SAP application server by default.

Note

In the case of alternating operation of hosts of this type, the hosts work with monitoring segments with the same name, meaning that the data is reported in the same tree in the Alert Monitor. The contents of the segment is saved to the files ALMTTREE, ALALERTS, and ALPERFHIS during the shutdown of a host. If you now ensure that these AL* files are accessible from both hosts, the contents of the segment are not disturbed by switching host.

ipc/shm_permission_1008

If you are using the SAPCCMSR agent to monitor a host with multiple J2EE servers, you must ensure that this profile parameter has the value 10777. This means that the J2EE Servers can write tot he shared memory of the agent, even if they are not running under the same user.

The first process, which creates the shared memory, must therefore set the parameter with the command ipc/shm_permission_1008=100777. This can be SAPCCMSR (in this case, add the line to the SAPCCMSR profile file), however it could also be the J2EE Engine.

Example

You are registering the CCMS agent SAPCCMSR under Microsoft Windows and specify a profile file with the parameter pf=. This would have the following content:

# Monitoring segment of the shared memory in bytes
# (For the default size, see SAP Note 135503)
alert/MONI_SEGM_SIZE = 20000000

# Working directory of the agent
# (Default for Microsoft Windows NT: \\host\saploc\prfclog\sapccmsr)
DIR_PERF = c:\ccms-agenten\sapccmsr

# Path and complete name of the operating system collector SAPOSCOL
# (required so that the agent can control the collector)
exe/saposcol = c:\saploc\saposcol.exe

Downloading CCMS Agents

Use

If you want to use the CCMS agents to monitor your system landscape, you can download these from the SAP Service Marketplace.

Prerequisites

You must first clarify which of the CCMS agents is suitable for your system:

CCMS Agent

Suitable for:

SAPCCMSR

Components with no SAP instance;
Central monitoring system as of SAP Basis 4.6B

SAPCCM4X

SAP systems as of SAP Basis 4.X;
Central monitoring system as of SAP Basis 4.6C

SAPCM3X

SAP systems with SAP Basis 3.X

Procedure

1. You require the file CCMAGENT.SAR. This archive contains all CCMS agents, including SAPCCMSR, SAPCCM4X, and SAPCM3X.


We recommend that you use the newest version of each agent. You can determine the version of a CCMS agent with the option–V(see Controlling CCMS Agents).

The archive also contains the availability agent CCMSPING. For more information, see Structure linkAvailability Monitoring

2. You can find CCMAGENT.SAR in the Software Catalog of the SAP Service Marketplace (http://service.sap.com/patches). Log on using your SAP Service Marketplace ID. Check the following folders in the specified order for this file, and download it:

¡ In the navigation bar, choose SAP WEB AS ® SAP WEB AS 6.20 ® Binary Patches ® SAP KERNEL 6.20/SAP KERNEL 6.20 64-BIT ® ® Database Independent.

¡ Only if the required archive is not in the above folder, choose SAP R/3 ® SAP R/3 4.6C ® Binary Patches ® SAP Kernel 4.6D/SAP KERNEL 4.6D 64-BIT ® ® Database Independent.

The reason for specifying multiple folders is that CCMS agents are partly dependent on the operating system release. Agents for a current SAP release may no longer cover all available operating system releases (for example, agents for SAP Web Application Server 6.20 are supported only on HP-UX 11.x; however, there are still application servers to be monitored that are running on HP-UX 10.x).


· You can determine the version of the CCMS agents in CCMAGENT.SAR by displaying the associated Info File.

· If you require an agent for an older operating system release that is not in the folders above, SAP also provides the newest CCMS agent functions in patches to older SAP Basis releases (especially SAP Basis 4.6D), as far as possible.

3. Decompress the CCMAGENT.SAR archive with the SAPCAR tool. Take account of SAP Note 212876 (The new archiving tool SAPCAR).


All CCMS agents are backward compatible in relation to the SAP Basis release. This means that:

· The release of the agent may be higher than the release of the central monitoring system with which the agent is communicating. We do, however, recommend that you use as high a release status as possible for the central monitoring system.

· For agent SAPCCM4X, the release of the agent can be higher than the SAP Basis release of the monitored SAP application server.