Monitoring Java EE Components

Chapter 1 Monitoring Java EE Components

The topics listed here provide information about how to monitor JavaTM Platform, Enterprise Edition ("JavaTM EE platform") components in Sun JavaTM Composite Application Platform Suite (Java CAPS) Repository-based projects at runtime.

If you have any questions or problems, see the Java CAPS web site at http://goldstar.stc.com/support.

Enterprise Manager Basics

Enterprise Manager is a web-based interface with which you can manage running Java CAPS applications for both the Java Platform, Enterprise Edition (Java EE platform) and the Schema Runtime Environment (SRE).

You can access Enterprise Manager with any of the following browsers:

Enterprise Manager contains an Explorer panel on the left and a Details panel on the right.

Java EE platform applications and SRE applications appear in different branches of the Explorer panel.

Screen capture of the Explorer panel.

Enterprise Manager also includes a command-line client.

Starting the Enterprise Manager Server

Before users can log in to Enterprise Manager, you must start the server component.

ProcedureTo Start the Enterprise Manager Server

  1. Run the start_emanager script in the JavaCAPS-install-dir directory.

  2. Wait for an INFO message that indicates the startup time in milliseconds. For example:


    INFO: Server startup in 130006 ms

    On UNIX platforms, this message appears in the catalina.out file in the JavaCAPS-install-dir/emanager/server/logs directory. On Windows platforms, this message appears in the command-line window.

Logging In to Enterprise Manager

Users log in to Enterprise Manager from a browser.

For detailed information about Enterprise Manager user names and passwords, see Managing Java CAPS Users.

This procedure assumes that the Enterprise Manager server has been started.

ProcedureTo Log In to Enterprise Manager

  1. In a supported browser, enter the following URL:


    http://hostname:portnumber/

    Set the hostname to the TCP/IP host name or IP address of the server where Enterprise Manager is installed. Set the port number to the port number that was specified during the installation of Enterprise Manager. For example:


    http://myserver.company.com:15000/

    The Enterprise Manager Security Gateway screen appears.

  2. In the User ID field, enter an Enterprise Manager user name.

  3. In the Password field, enter the corresponding password.

  4. Click Login.

    Enterprise Manager appears.

Adding an Application Server Domain to Enterprise Manager

In order to manage a Sun Java System Application Server domain in Enterprise Manager, you must first add the domain.

ProcedureTo Add an Application Server Domain to Enterprise Manager

  1. In the Explorer panel of Enterprise Manager, click the Java EE node.

    The Manage Servers tab appears.

  2. Enter the connection information.

    Field 

    Description 

    Server Type 

    The type of application server. Set this field to Sun Java System Application Server Domain (9.1) 

    Host Name 

    The fully qualified host name (for example, myhost.company.com) or IP address of the computer on which the application server is running.

    HTTP Administration Port 

    The port number of the Domain Administration Server. 

    User Name 

    The user name required to access the domain. 

    Password 

    The password required to access the domain. 

  3. Click Connect to Server.

    The application server domain is added to the Current Application Server List table.

    Screen capture of the Current Application Server List
table with the added server.

Adding an Application Server Instance to Enterprise Manager

In order to manage a Sun Java System Application Server instance in Enterprise Manager, you must first add the instance.

Managing instances is more limited than managing domains.

ProcedureTo Perform Prerequisite Steps on the Application Server

Before You Begin

In this procedure, you manage targets for the SeeBeyondSunOneDeployer web application and the logging connector module. These components are part of the Java CAPS runtime. The default application server domain includes the runtime. Any additional domains that you create do not include the runtime. Follow the steps in Java CAPS Runtime Installation to manually install the runtime on any additional domains.

  1. Log in to the Sun Java System Application Server Admin Console.

  2. In the left pane, expand the Web Applications node and select the SeeBeyondSunOneDeployer node.

  3. Click the Target tab.

  4. Click Manage Targets, add the instance to the Selected Targets list, and click OK.

  5. In the left pane, expand the Connector Modules node and select the logging node.

  6. Click the Target tab.

  7. Click Manage Targets, add the instance to the Selected Targets list, and click OK.

  8. Go to the asadmin tool.

  9. Stop and restart the instance.

ProcedureTo Add an Application Server Instance to Enterprise Manager

  1. In the Explorer panel of Enterprise Manager, click the Java EE node.

    The Manage Servers tab appears.

  2. Enter the connection information.

    Field 

    Description 

    Server Type 

    The type of application server. Set this field to Sun Java System Application Server Instance (9.1) 

    Host Name 

    The fully qualified host name (for example, myhost.company.com) or IP address of the computer on which the application server is running.

    HTTP Instance Port 

    The port number of the HTTP port that the instance is using. 

    Server Instance Name 

    The name of the instance. 

  3. Click Connect to Server.

    The application server instance is added to the Current Application Server List table.

    Screen capture of the Current Application Server List
table with the added server.

Using the Connectivity Map Controls

When you select a Connectivity Map node in the Explorer panel of Enterprise Manager, the actual Connectivity Map appears in the Details panel.

Screen capture of a Connectivity Map and the toolbar.

You can adjust the position of the Connectivity Map. In addition, you can zoom in and out.

In order to perform these tasks, you must enable the Zoom and Pan icon. The Zoom and Pan appears on the left of the toolbar. By default, the icon is disabled. To enable the icon, click the icon.

Screen capture of disabled Zoom and Pan icon.Screen capture of enabled Zoom and Pan icon.

If you are using Internet Explorer, then you must install the SVG Viewer in order for the zoom functionality to work correctly. Follow the steps in the Java CAPS installation documentation to upload the Enterprise_Manager_SVGPlugin-win32.sar file to the Repository. Then download the executable file to the computer where the browser is located. Run the executable file to install the SVG Viewer.

The 100%, Fit All, Fit Width, and Fit Height icons provide the following functionality:

ProcedureTo Adjust the Position of the Connectivity Map

  1. Press the Alt key.

    Your cursor becomes a hand symbol.

  2. Click the Connectivity Map and move it to the desired position.

ProcedureTo Zoom In on the Connectivity Map

  1. Click the Zoom In icon.

ProcedureTo Zoom Out from the Connectivity Map

  1. Click the Zoom Out icon.

ProcedureTo Specify an Exact Zoom Percentage

  1. Enter a whole number in the field between the Zoom Out and Zoom In icons.

Stopping the Enterprise Manager Server

You use a script to stop the server component of Enterprise Manager.

ProcedureTo Stop the Enterprise Manager Server

  1. Run the stop_emanager script in the JavaCAPS-install-dir directory.

Monitoring Application Servers

Enterprise Manager enables you to monitor application servers at runtime. You can perform the following tasks:

For information about monitoring logs, see Monitoring Logs. For information about monitoring alerts, see Monitoring Alerts.

For basic information about Enterprise Manager, see Enterprise Manager Basics.

Viewing Basic Information About an Application Server

You can view basic information about an application server from Enterprise Manager.

Screen capture of the Status tab, which shows basic information
about an application server.

ProcedureTo View Basic Information About an Application Server

  1. In the Explorer panel of Enterprise Manager, select the application server.

    The Status tab appears.

  2. View the information.

    The HostAndPort row displays the computer name and administrative port on which the application server is running.

    The System row indicates whether the application server is located in the Java EE or SRE portion of the Explorer panel.

    The Component row displays the hierarchy of the application server in the Explorer panel.

    The State row specifies the current status of the application server. The valid values are Up and Down.

    The RestartRequired row is set to true when you must restart the application server because of configuration changes.

Viewing Summary Information For an Application Server

You can view summary information for an application server from Enterprise Manager.

ProcedureTo View Summary Information for an Application Server

  1. In the Explorer panel of Enterprise Manager, select the application server.

  2. Click the Summary tab.

    The Summary tab displays icons for the Connectivity Map components and message servers that are running in the domain.

Stopping Application Server Domains

You can stop an application server domain from Enterprise Manager.


Note –

You cannot stop an application server instance from Enterprise Manager. Furthermore, you cannot start an application server domain or an application server instance from Enterprise Manager.


ProcedureTo Stop an Application Server Domain

  1. In the Explorer panel of Enterprise Manager, select the application server domain.

  2. Click Stop.

Hiding, Showing, and Removing Application Servers

You can hide, show, and remove application servers in the Explorer panel of Enterprise Manager.

ProcedureTo Hide an Application Server

  1. In the Explorer panel of Enterprise Manager, right-click the application server and click Hide.

    The server is hidden.

ProcedureTo Make All of the Hidden Application Servers Reappear

  1. In the Explorer panel of Enterprise Manager, right-click the Servers node and click Show All Servers.

    The hidden server or servers reappear.

ProcedureTo Maintain the Current Configuration of Hidden and Displayed Application Servers Between Enterprise Manager Sessions

  1. In the Explorer panel of Enterprise Manager, click the Save Current User Preferences icon.


    Note –

    If you change the configuration and you attempt to log out without saving the preferences, then Enterprise Manager displays a prompt that enables you to save the preferences.


ProcedureTo Remove an Application Server

Before You Begin

You must be an Enterprise Manager user that has the Manager role.

  1. In the Explorer panel of Enterprise Manager, right-click the application server and click Remove.

  2. When prompted to confirm, click OK.

    The server is removed.

Monitoring Collaborations

Enterprise Manager enables you to monitor Collaborations at runtime. You can perform the following tasks:

For information about monitoring logs, see Monitoring Logs. For information about monitoring alerts, see Monitoring Alerts.

For basic information about Enterprise Manager, see Enterprise Manager Basics.

Viewing Basic Information About a Collaboration

You can view basic information about a Collaboration from Enterprise Manager.

Screen capture of the Status tab, which shows basic information
about a Collaboration.

ProcedureTo View Basic Information About a Collaboration

  1. In the Explorer panel of Enterprise Manager, select the Collaboration.


    Note –

    If the Connectivity Map is displayed in the Details panel, you can select the Collaboration in the Connectivity Map.


    The Status tab appears.

  2. View the information.

    The HostAndPort row displays the computer name and administrative port on which the Collaboration is running.

    The System row indicates whether the Collaboration is located in the Java EE or SRE portion of the Explorer panel.

    The Component row displays the hierarchy of the Collaboration in the Explorer panel.

    The State row specifies the current status of the Collaboration.

    The Since row indicates when the current status began.

    The Type row indicates the category of Collaboration (for example, JCE Collaboration).

    If the Collaboration subscribes to a topic, then the Subscriber row lists the subscriber name used by the Collaboration.

    The Processed row lists the number of messages that the Collaboration has processed.

    If the input to the Collaboration is a topic or queue, then the Waiting row lists the number of messages that are waiting to be processed by the Collaboration.

Viewing Consumption Information For a Collaboration

You can view statistics about the consumption of messages by a Collaboration.

ProcedureTo View Consumption Information For a Collaboration

  1. In the Explorer panel of Enterprise Manager, select the Collaboration.


    Note –

    If the Connectivity Map is displayed in the Details panel, you can select the Collaboration in the Connectivity Map.


  2. Click the Consumption tab.

    The Waiting To Be Processed graphic lists the number of messages that are waiting to be processed by the Collaboration. This graphic appears only if the input to the Collaboration is a topic or queue.

    The Processed By Collaboration graphic lists the number of messages that the Collaboration has processed.

Viewing Summary Information For a Collaboration

You can view summary information for a Collaboration.

ProcedureTo View Summary Information For a Collaboration

  1. In the Explorer panel of Enterprise Manager, select the Collaboration.

  2. Click the Summary tab.

    The Summary tab displays icons for the Connectivity Map components and JMS IQ Managers that are running in the domain.

Stopping and Restarting Collaborations

You can stop and restart Collaborations from Enterprise Manager.

ProcedureTo Stop a Collaboration

  1. In the Explorer panel of Enterprise Manager, select the Collaboration.

  2. Click Stop.

ProcedureTo Restart a Collaboration

  1. In the Explorer panel of Enterprise Manager, select the Collaboration.

  2. Click Restart.

Monitoring Adapters

Enterprise Manager enables you to display information about Adapters, as well as to start or stop inbound Adapters.

Before you begin, ensure that the relevant Enterprise Manager plug-ins have been added for the Adapters that you want to monitor. The available plug-ins appear in the Downloads page of the Java CAPS Uploader. However, you install the plug-ins from Enterprise Manager. For detailed information about how to install the plug-ins, see Using Enterprise Manager Management Applications in Java CAPS.

For basic information about Enterprise Manager, see Enterprise Manager Basics.

Displaying Information About an Adapter

Enterprise Manager contains a framework for displaying read-only information about Adapters.

Screen capture of the read-only information for an Adapter.

ProcedureTo Display Information About an Adapter

  1. In the Explorer panel of Enterprise Manager, expand the nodes of the application server and then select the Adapter.


    Note –

    If the Connectivity Map is displayed in the Details panel, you can select the Adapter in the Connectivity Map.


    The Details panel contains a tree component on the left.

  2. Click a node in the tree to display information for that node.

  3. The top node contains the properties described in the following table.

    Property 

    Description 

    System 

    Indicates whether the Adapter is located in the Java EE or SRE portion of the Explorer panel. 

    Host:Port 

    The URL of the server in which the Adapter is deployed. 

    Component Type 

    An internal term for the Adapter. 

    Connection Type 

    Indicates whether the Adapter is being used in inbound or outbound mode. 

    State 

    Indicates whether the Adapter is started or stopped. 

  4. The Config Property node (under the Connector Details node) contains the properties described in the following table.

    Property 

    Description 

    EwayResourceAdapterMBeanName 

    The name of the managed bean for the Adapter.

    EwayName 

    The name of the Adapter. 

    EwayDescription 

    A brief description of the Adapter. 

    EwayVersion 

    The version number of the Adapter. 

    SupportedModes

    A value of Inbound means that the Adapter supports receiving events from the external system by polling or listening. This is the server mode.

    A value of Outbound means that the Adapter supports client mode (that is, the client is an external system).

    A value of Inbound_Outbound means that the Adapter supports both inbound and outbound modes.

  5. The properties of the nodes under the Configuration node are specific to each Adapter. The developer sets the values from the IDE.

  6. For information about the Alerts node, see Monitoring Alerts.

  7. For information about the Logging node, see Monitoring Logs.

Stopping and Starting Inbound Adapters

When you stop an inbound Adapter, the Adapter remains deployed. However, the Adapter is suspended until you start it again.

You cannot stop and start outbound Adapters.

ProcedureTo Stop an Inbound Adapter

  1. In the Explorer panel of Enterprise Manager, select a Connectivity Map.

  2. In the Details panel of Enterprise Manager, click the External Application.

  3. Click Stop.

ProcedureTo Start an Inbound Adapter

  1. In the Explorer panel of Enterprise Manager, select a Connectivity Map.

  2. In the Details panel of Enterprise Manager, click the External Application.

  3. Click Start.

Monitoring Logs

Enterprise Manager enables you to view the log files for the following components:

For basic information about Enterprise Manager, see Enterprise Manager Basics.

Viewing the Application Server Log File

Enterprise Manager enables you to view the server log file for the Sun Java System Application Server.

Screen capture of the Logging tab in Enterprise Manager. A small
portion of the application server log file is shown.

ProcedureTo View the Application Server Log File

  1. In the Explorer panel of Enterprise Manager, select an application server, Collaboration, or Adapter.

  2. Click the Logging tab or node.

    The application server log file appears.

  3. To filter the log messages for a specific log level and above, change the setting of the Log Level drop-down list and click the Search icon.

    For example, if you select the WARNING log level, then Enterprise Manager displays any WARNING and SEVERE log messages.

  4. To perform a regular expression search, use the Regexp Filter field.

    The search is case sensitive.

    You can enter multiple filters by using an ampersand (&). Here are two examples:


    INFO & MBean
    Project1 & Service1
  5. To change the number of lines that appear in each page, change the setting of the Lines/Page drop-down list and click the Search icon.

  6. To open the log messages in a new window, click the Detach Window icon.

  7. To search for a string in the log file, enter a string in the Search On Page For field and click the Find On a Page or Find All On a Page icon.

    The string must be at least three characters.

    The Clear Results icon enables you to remove the highlighting of the search results.

Viewing the Message Server Log File

Enterprise Manager enables you to view the log file for Sun Java System Message Queue and Sun JMS IQ Manager.

ProcedureTo View the Message Server Log File

  1. In the Explorer panel of Enterprise Manager, select the message server node (for example, IQ_Manager_18007 or Sun_JMQ_7676).

  2. Click the Logging tab.

    The log file appears.

  3. To filter the log messages for a specific log level and above, change the setting of the Log Level drop-down list and click the Search icon.

    For example, if you select the WARNING log level, then Enterprise Manager displays any WARNING and SEVERE log messages.

  4. To perform a regular expression search, use the Regexp Filter field.

    The search is case sensitive.

    You can enter multiple filters by using an ampersand (&). Here are two examples:


    INFO & MBean
    Project1 & Service1
  5. To change the number of lines that appear in each page, change the setting of the Lines/Page drop-down list and click the Search icon.

  6. To open the log messages in a new window, click the Detach Window icon.

  7. To search for a string in the log file, enter a string in the Search On Page For field and click the Find On a Page or Find All On a Page icon.

    The string must be at least three characters.

    The Clear Results icon enables you to remove the highlighting of the search results.

Monitoring Alerts

Enterprise Manager enables you to monitor alerts at runtime. You can perform the following tasks:

For basic information about Enterprise Manager, see Enterprise Manager Basics.

Java CAPS provides an Alert Management API. For detailed information about the Alert Management API, see Java CAPS Management and Monitoring APIs.

Alerts Overview

An alert is triggered when a specified condition occurs in a Project component. The condition might represent a problem that must be corrected, or the condition might be informational.

The following table lists the predefined alerts for Sun Enterprise Service Bus. Each predefined alert is identified by a code, such as COL-00001. The alert also includes a description, such as Collaboration running.

Table 1–1 Predefined Alerts for Sun Enterprise Service Bus

Code 

Description 

Recommended Action 

COL-00001 

The Collaboration is running. 

This alert does not indicate any malfunction. No user actions are necessary. 

COL-00002 

The Collaboration stopped. 

No recommended action. 

COL-00003 

Collaboration user-defined alert 

The recommended action depends on the purpose of the user-defined alert. 

MS-00009 

The Message Server has reached the throttling threshold of total number of messages. 

For topics, you must wait for the subscribers to consume more messages. In the meantime, stop attempting to deliver messages to the JMS IQ Manager. 

For queues, you must wait for the receivers to consume more messages. In addition, you can try adding receivers to improve the throughput. 

If you can stop the runtime application and restart the application server, then increase the server throttling threshold. 

MS-00010 

The Message Server has moved below the throttling threshold of total number of messages. 

No recommended action. 

MS-00011 

The Message Server has reached the throttling threshold for message destinations. 

No recommended action. 

MS-00012 

The Message Server has moved below the throttling threshold for message destinations. 

No recommended action. 

To view information about the predefined alerts for Adapters, see Alert Codes for Java CAPS Adapters.

Project developers can add custom alerts.

The initial status of an alert is Unobserved. You can change the status to Observed or Resolved. Observed indicates that you looked at and acknowledged the alert. Resolved indicates that you fixed the problem that caused the alert.

By default, alerts are not persisted to an external database. For information about configuring persistence, see Configuring Alert Persistence.

Viewing Alerts

You can view alerts at runtime. In addition, you can change the status of an alert.

Screen capture of the Alerts tab in Enterprise Manager. Various
alerts are shown.

ProcedureTo View Alerts

  1. In the Explorer panel of Enterprise Manager, select an application server, project component, or message server.

  2. Click the Alerts tab or node.

    The alerts for the selected component appear.

    The summary row below the tabs displays the total number of alerts for each alert type (Fatal, Critical, Major, Minor, Warning, and Info).

    The toolbar appears below the summary row.

  3. By default, the alerts are sorted by date/time in reverse chronological order. To sort the alerts by different criteria, click the up/down arrows in the desired column.

  4. To select all of the alerts, click the Select All icon.

  5. To deselect the currently selected alerts, click the Select None icon.

ProcedureTo View Alert Details

  1. Either double-click the alert, or select the alert and click the View Details icon.

    The Alert Details dialog box appears.

  2. When you are done, click Close.

ProcedureTo Change the Status of an Alert

  1. Select the alert.

  2. Click the Set Observed icon or Set Resolved icon.

    You can also reset the status to Unobserved by clicking the Reset icon.

Filtering Alerts

You can control which alerts appear in Enterprise Manager.

ProcedureTo Filter Alerts

  1. In the Explorer panel of Enterprise Manager, select an application server, project component, or message server.

  2. Click the Alerts tab or node.

    The alerts for the selected component appear.

  3. Click the Filter icon.

    The Alerts Filter dialog box appears. The fields that appear in the dialog box depend on the type of component that you selected in the Explorer panel.

  4. Specify one or more fields.

  5. Click Submit.

ProcedureTo Remove the Filter

  1. Do either of the following:

    • Click the Clear Filter icon.

    • Click the Filter icon, click Clear, and click Submit.

Deleting Alerts

You can delete a single alert, or multiple alerts at a time.

ProcedureTo Delete an Alert

  1. In the Explorer panel of Enterprise Manager, select an application server, project component, or message server.

  2. Click the Alerts tab or node.

    The alerts for the selected component appear.

  3. Select the alert.

  4. Click the Delete icon or press the Delete key.

    A confirmation dialog box appears.

  5. Click OK.

ProcedureTo Delete More Than One Alert at a Time

  1. Select the alerts that you want to delete.

    • To select all of the alerts, click the Select All icon.

    • To select alerts that may or may not be contiguous, use the CTRL key.

    • To select a contiguous range of alerts, click an alert at one end of the range, press the SHIFT key, and click the alert at the other end of the range.

  2. Click the Delete icon or press the Delete key.

    A confirmation dialog box appears.

  3. Click OK.

ProcedureTo Delete All Alerts For the Selected Component

  1. Click the Delete All icon.

    A confirmation dialog box appears.

  2. Click OK.


    Note –

    If an alert does not currently appear because of a filter, then the alert is not deleted. See Filtering Alerts.


Configuring Alert Persistence

The alert persistence architecture includes the following databases.

Diagram of the embedded database and an external database.

By default, alerts are not persisted to the external database. This topic describes how to enable persistence.

Be sure to understand the behavior of the various persistence configurations.

You can use any of the following database types for the external database. The Derby database is included with Sun Java System Application Server. The other database types are not included.

If you want to use a database type other Derby, then you must perform additional configuration tasks. For example, you must use JavaTM DataBase Connectivity ("JDBCTM") software and the Java Naming and Directory InterfaceTM ("J.N.D.I.") API to set up access to the database.

For all database types, you must log in to the Configuration Agent and modify the alert notification fields.

ProcedureTo Configure the Alert Table Name (Databases Other Than Derby)

  1. Open the eventmanagement.properties file in the JavaCAPS-install-dir/appserver/domains/domain-name/jbi/config directory.

  2. If necessary, change the default value of the AlertTableName property and save the file.

    You might need to change the default value to match your organization's naming conventions, or to comply with the database server's character limit for table names.

ProcedureTo Set Up Database Access (Databases Other Than Derby)

  1. Log in to the Sun Java System Application Server Admin Console.

  2. Integrate the JDBC driver.

    You can make the driver accessible to the common class loader or the system class loader.

    For detailed information about how to integrate a JDBC driver, click Help in the Admin Console.

  3. In the left pane, expand the Resources node and the JDBC node, and select the Connection Pools node.

  4. Click New.

  5. Create the JDBC connection pool.

    For detailed information about how to create a JDBC connection pool, click Help in the Admin Console.

  6. In the left pane, select the JDBC Resources node.

  7. Click New.

  8. Create the JDBC resource.

    You will enter the JNDI name of the JDBC resource in a later procedure.

    Set the pool name to the JDBC connection pool that you just created.

    For detailed information about how to create a JDBC resource, click Help in the Admin Console.

ProcedureTo Run the Database Scripts (Databases Other Than Derby)

  1. Open the jbi_rt.jar file in the JavaCAPS-install-dir/appserver/jbi/lib directory.

  2. Extract the SQL scripts for your database type.

  3. If you are using Oracle, then create the tablespace and user that will be used to persist alerts.

    1. Open the create_event_store_user.sql script and make any changes needed to match your database configuration.

    2. Run the create_event_store_user.sql script.

  4. Create the table that will be used to persist alerts.

    1. Open the create_event_store_schema.sql script and make any changes needed to match your database configuration.

      Ensure that the table name matches the value in the eventmanagement.properties file.

    2. Run the create_event_store_schema.sql script.

ProcedureTo Log In to the Configuration Agent

  1. If the application server is not running, then start the application server.

  2. In a browser, enter the following URL:

    http://hostname:portnumber/configagent

    Set the hostname to the TCP/IP host name of the computer where the application server is installed. Set the port number to the administration port number of the application server. For example:

    http://myserver.company.com:4848/configagent

    The Configuration Agent Security Gateway appears.

  3. In the User ID field, enter an application server user name.

  4. In the Password field, enter the corresponding password.

  5. Click Login.

    The Configuration Agent appears.

ProcedureTo Modify the Alert Notification Fields

  1. Ensure that the database is running.

  2. In the Configuration Agent, click the Alert Management Configuration tab.

    Screen capture of the Alert Management Configuration
tab
  3. Select the Enabled check box to the right of the Alert Notification Persistence label.

  4. If you want to enable journaling, then select the Enabled check box to the right of the Alert Notification Journal label.

  5. Select the database type from the Alert Notification Database Type drop-down list.

  6. If you are using a database other than Derby, then set the JNDI name to the JNDI name of the JDBC resource that you created.

  7. Click Save.

  8. Restart the application server domain.

Archiving Alerts

You can archive the alerts in Enterprise Manager's embedded database. The archive process writes the alerts to .csv files in the JavaCAPS-install-dir/emanager/EventRepositoryDb directory.

The eventdb_archive.properties file in the JavaCAPS-install-dir/emanager/server/shared/classes directory enables you to configure the archive process. The following table describes the properties.

Table 1–2 Alert Archive Properties

Property 

Description 

GROUP_MAX_COUNT 

A group is a set of alerts that have the same values for the following fields: Environment, Physical Host, Logical Host, Server, Deployment, Component, and Message Code. This property specifies the maximum number of alerts that can be in a group. When the number is exceeded, the oldest rows exceeding this number are archived. 

If the value is 0, then the archive process ignores this property. 

MAX_TIME_DELTA_FOR_ARCHIVE 

The maximum amount of time (in milliseconds) that can elapse between archive operations. 

If the value is 0, then the archive process ignores this property. 

MAX_EVENT_COUNT_FOR_ARCHIVE 

The archive process is run when this number of alerts is reached. 

If the value is 0, then the archive process ignores this property. 

MAX_AGE_OF_EVENTS 

When the archive process is run, alerts that exceed this age limit (in milliseconds) are archived. 

If the value is 0, then the archive process ignores this property. 

MAX_ROWCOUNTLIMIT_IN_ARCHIVE_FILE 

The maximum number of records that can be stored in a .csv file. When this number is reached, the archive process creates a new .csv file. 

If you change the value of one or more properties, then you must restart the Enterprise Manager server in order for the changes to take effect. See Enterprise Manager Basics.

Reducing Duplicate Alerts

In certain situations, a large number of alerts can be generated in a short period of time. For example, a system goes down and messages are repeatedly attempted to be processed.

You can use a property to reduce the number of alerts that appear. The property value is expressed in milliseconds. The default value is 5000, which equals 5 seconds. If multiple instances of an alert arrive during this period of time, then only one instance of the alert will appear.

A string is added to the beginning of the alert details field. The string indicates the number of duplicate alerts that were processed. For example:


[3x] Collaboration CMap1_jcdFileToJMS1 is RUNNING

ProcedureTo Reduce Duplicate Alerts

  1. Open the monitor.properties file in the JavaCAPS-install-dir/emanager/server/conf directory.

  2. Change the value of the timeInCache property to the desired number of milliseconds.

  3. Save the monitor.properties file.

  4. Restart the Enterprise Manager server.

Monitoring Sun JMS IQ Manager

Enterprise Manager enables you to manage Sun JMS IQ Manager. You can perform the following tasks:


Note –

Enterprise Manager provides a unified management environment for Sun JMS IQ Manager, Sun Java System Message Queue, and Sun Java Message Service Grid (JMS Grid). However, the level of monitoring and management capabilities supported vary for the different message servers.


For basic information about Enterprise Manager, see Enterprise Manager Basics.

A topic conforms to the publish-and-subscribe (pub/sub) messaging domain, where one publisher broadcasts messages to potentially many subscribers. When the message server publishes a message on a topic, it ensures that all subscribers receive the message.

A queue conforms to the point-to-point (p2p, or PTP) messaging domain, where one sender delivers a message to exactly one receiver. When the message server sends a message to a queue, it ensures that the message is received once and only once, even though there might be many receivers “listening” to the queue. This is equivalent to the subscriber pooling in other queue implementations.

Except for this distinction between pub/sub and PTP, topics and queues are quite similar.

Monitoring Topics and Queues

You can use Enterprise Manager to monitor message traffic in topics and queues.

ProcedureTo Monitor Topics and Queues

  1. In the Explorer panel of Enterprise Manager, select the JMS IQ Manager node (for example, IQ_Manager_18007).

  2. In the Details panel, click the Topics tab.

    The following table describes the columns in the Topics tab.

    Column Name 

    Description 

    Topic Name 

    The name of the topic. 

    Min Sequence Number 

    The sequence number of the oldest message available for this topic. If no messages are available, this column shows the sequence number of the last message processed. 

    Max Sequence Number 

    The sequence number of the most recent message available for this topic. If no messages are available, this column shows the sequence number of the last message processed. 

    Available Count 

    The number of messages for this topic that are still unprocessed by at least one subscriber. 

    Number of Subscribers 

    The number of subscribers registered to consume messages for this topic (including durable subscribers that are currently disconnected). 

    Last Published Date/Time 

    The date and timestamp of the most recent message currently available in the topic. If no messages are available, this column shows the last publication date and time of the last message. 

  3. Click the Queues tab.

    The following table describes the columns in the Queues tab.

    Column Name 

    Description 

    Queue Name 

    The name of the queue. 

    Min Sequence Number 

    The sequence number of the oldest message available for this queue. If no messages are available, this column shows the sequence number of the last message processed. 

    Max Sequence Number 

    The sequence number of the most recent message available for this queue. If no messages are available, this column shows the sequence number of the last message processed. 

    Available Count 

    The number of unprocessed messages in the queue. 

    Number of Receivers 

    The number of receivers for this queue. 

    Last Published Date/Time 

    The date and timestamp of the most recent message currently available in the queue. If no messages are available, this column shows the last publication date and time of the last message. 

  4. When you select a topic or queue, the Messages tab in the lower portion of the Details panel displays information about the topic or queue. The Messages tab includes a toolbar.

  5. If journaling is enabled, then you can switch between displaying live and journaled messages by clicking the Show Live and Show Journaled icons in the toolbar. If journaling is not enabled, then these buttons do not appear.

  6. Topics also include a Summary tab and a Subscribers tab. The Subscribers tab displays information about durable subscribers. The toolbar enables you to create a new durable subscriber and to unsubscribe an existing durable subscriber.

Sending and Publishing Messages

You can send and publish messages from Enterprise Manager. The messages can be text or binary.

ProcedureTo Send and Publish Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, click the Send/Publish icon.

    The Send/Publish New Message dialog box appears.

  3. If you want to publish a text message, then select the Text option and enter the text or specify the text file.

  4. If you want to publish a binary message, then select the Binary option and specify the binary file.

  5. Review the default values for the Time to Live, Priority, and Delivery Mode fields. If desired, change the default values.

    The Time to Live field has a default value of 0, which specifies that the message does not expire.

  6. Click Submit.

Viewing Message Properties

You can view the properties of a message. The properties include the message type, destination name, and expiration time.

ProcedureTo View Message Properties

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the Properties icon.

    The View Message Property dialog box appears. The following table describes the message properties.

    Property Name 

    Description 

    Correlation ID 

    An identifier that is used to associate the message with a previous message or application-specific identifier. The default internal value is Sun-SeeBeyond.

    Time Stamp 

    The date and time when the message was received. 

    Message Payload Size 

    The size of the message payload (in bytes). 

    Message Source File 

    If the message is persistent, then this property displays the fully qualified name of the database file in which the message is stored. 

    Type 

    The message type of the message, such as text or bytes. 

    Message Enqueue Time 

    The date and time when the message was received by its message destination. 

    Delivery Mode 

    Indicates whether the message is persistent or nonpersistent. 

    Message Size 

    The size of the message including the JMS header (in bytes). 

    Sequence Number 

    The sequence number of the message. 

    Redelivery Flag 

    Indicates whether this message is set for redelivery. 

    Destination Name 

    The name of the topic or queue. 

    Message ID 

    The unique identification number for the message. 

    Priority 

    The priority of the message from 0 to 9. The lowest priority is 0. The highest priority is 9. 

    Expiration Time 

    The date and time when the message will expire. 

    Message Body Size 

    The size of the message body (in bytes). 

  3. When you are done, click Close.

Viewing and Editing Message Payload

A message contains two main components: the headers and the payload. The headers contain metadata about the message. The payload contains the actual content of the message.

Text Messages

Enterprise Manager enables you to view and edit the payload of live text messages. In addition, you can view and republish the payload of journaled text messages.

ProcedureTo View and Edit the Payload of Live Text Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the View/Edit icon.

    The Text Message Payload (Live) dialog box appears.

  3. To display any carriage return and line feed characters in the message, select the Show Carriage Return/Line Feed check box.

  4. If the message contains XML and you want to view the XML in browser format, click View XML.

  5. To change the payload, do one of the following:

    • Modify the text in the text area and click Change Payload.

    • Select the From File option, select the text file, and click Change Payload.

  6. To delete the message, click Delete.

  7. To save the payload to a file, click Download Payload.

ProcedureTo View and Republish the Payload of Journaled Text Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the View/Edit icon.

    The Text Message Payload (Journaled) dialog box appears.

  3. To display any carriage return and line feed characters in the message, select the Show Carriage Return/Line Feed check box.

  4. If the message contains XML and you want to view the XML in browser format, click View XML.

  5. To republish the payload to a topic or queue, click Republish.

  6. To save the payload to a file, click Download Payload.

Byte Messages

Enterprise Manager enables you to view the payload of live byte messages. You cannot edit the payload.

ProcedureTo View the Payload of Live Byte Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the View/Edit icon.

    The Bytes Message Payload (Live) dialog box appears.

  3. To delete the message, click Delete.

  4. To save the payload to a file, click Download Payload.

Monitoring Sun JavaTM System Message Queue

Enterprise Manager enables you to manage Sun JavaTM System Message Queue. You can perform the following tasks:


Note –

Enterprise Manager provides a unified management environment for Sun JMS IQ Manager, Sun Java System Message Queue, and Sun Java Message Service Grid (JMS Grid). However, the level of monitoring and management capabilities supported vary for the different message servers.


For basic information about Enterprise Manager, see Enterprise Manager Basics.

A topic conforms to the publish-and-subscribe (pub/sub) messaging domain, where one publisher broadcasts messages to potentially many subscribers. When the message server publishes a message on a topic, it ensures that all subscribers receive the message.

A queue conforms to the point-to-point (p2p, or PTP) messaging domain, where one sender delivers a message to exactly one receiver. When the message server sends a message to a queue, it ensures that the message is received once and only once, even though there might be many receivers “listening” to the queue. This is equivalent to the subscriber pooling in other queue implementations.

Except for this distinction between pub/sub and PTP, topics and queues are quite similar.

Monitoring Topics and Queues

You can use Enterprise Manager to monitor message traffic in topics and queues.

ProcedureTo Monitor Topics and Queues

  1. In the Explorer panel of Enterprise Manager, select the Sun Java System Message Queue node (for example, Sun_JMQ_7676).

    The following table describes the columns that appear for a topic.

    Column Name 

    Description 

    Topic Name 

    The name of the topic. 

    Min Sequence Number 

    This column is not applicable to Sun Java System Message Queue. 

    Max Sequence Number 

    This column is not applicable to Sun Java System Message Queue. 

    Available Count 

    The number of messages for this topic that are still unprocessed by at least one subscriber. 

    Number of Subscribers 

    The number of subscribers registered to consume messages for this topic (including durable subscribers that are currently disconnected). 

    Last Published Date/Time 

    This column is not applicable to Sun Java System Message Queue. 

    The following table describes the columns that appear for a queue.

    Column Name 

    Description 

    Queue Name 

    The name of the queue. 

    Min Sequence Number 

    This column is not applicable to Sun Java System Message Queue. 

    Max Sequence Number 

    This column is not applicable to Sun Java System Message Queue. 

    Available Count 

    The number of unprocessed messages in the queue. 

    Number of Receivers 

    The number of receivers for this queue. 

    Last Published Date/Time 

    This column is not applicable to Sun Java System Message Queue. 

  2. The Messages tab in the lower portion of the Details panel displays information about any messages in the topic or queue. The Messages tab includes a toolbar.

  3. Topics also include a Summary tab and a Subscribers tab. The Subscribers tab displays information about durable subscribers. The toolbar enables you to create a new durable subscriber and to unsubscribe an existing durable subscriber.

Sending and Publishing Messages

You can send and publish messages from Enterprise Manager. The messages can be text or binary.

ProcedureTo Send and Publish Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, click the Send/Publish icon.

    The Send/Publish New Message dialog box appears.

  3. If you want to publish a text message, then select the Text option and enter the text or specify the text file.

  4. If you want to publish a binary message, then select the Binary option and specify the binary file.

  5. Review the default values for the Time to Live, Priority, and Delivery Mode fields. If desired, change the default values.

    The Time to Live field has a default value of 0, which specifies that the message does not expire.

  6. Click Submit.

Viewing Message Properties

You can view the properties of a message. The properties include the message type, destination name, and expiration time.

ProcedureTo View Message Properties

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the Properties icon.

    The View Message Property dialog box appears. The following table describes the message properties.

    Property Name 

    Description 

    Correlation ID 

    An identifier that is used to associate the message with a previous message or application-specific identifier. The default internal value is Sun-SeeBeyond.

    Time Stamp 

    The date and time when the message was received. 

    Message Payload Size 

    This property is not applicable to Sun Java System Message Queue. 

    Message Source File 

    This property is not applicable to Sun Java System Message Queue. 

    Type 

    The message type of the message, such as text or bytes. 

    Message Enqueue Time 

    The date and time when the message was received by its message destination. 

    Delivery Mode 

    Indicates whether the message is persistent or nonpersistent. 

    Message Size 

    This property is not applicable to Sun Java System Message Queue. 

    Sequence Number 

    The sequence number of the message. 

    Redelivery Flag 

    Indicates whether this message is set for redelivery. 

    Destination Name 

    The name of the topic or queue. 

    Message ID 

    The unique identification number for the message. 

    Priority 

    The priority of the message from 0 to 9. The lowest priority is 0. The highest priority is 9. 

    Expiration Time 

    The date and time when the message will expire. 

  3. When you are done, click Close.

Viewing and Editing Message Payload

A message contains two main components: the headers and the payload. The headers contain metadata about the message. The payload contains the actual content of the message.

Text Messages

Enterprise Manager enables you to view and edit the payload of live text messages.

ProcedureTo View and Edit the Payload of Live Text Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the View/Edit icon.

    The Text Message Payload (Live) dialog box appears.

  3. To display any carriage return and line feed characters in the message, select the Show Carriage Return/Line Feed check box.

  4. If the message contains XML and you want to view the XML in browser format, click View XML.

  5. To change the payload, do one of the following:

    • Modify the text in the text area and click Change Payload.

    • Select the From File option, select the text file, and click Change Payload.

  6. To delete the message, click Delete.

  7. To save the payload to a file, click Download Payload.

Byte Messages

Enterprise Manager enables you to view the payload of live byte messages. You cannot edit the payload.

ProcedureTo View the Payload of Live Byte Messages

  1. Select the topic or queue as described in Monitoring Topics and Queues.

  2. In the Messages tab, select the message and click the View/Edit icon.

    The Bytes Message Payload (Live) dialog box appears.

  3. To delete the message, click Delete.

  4. To save the payload to a file, click Download Payload.

Monitoring Java Message Service Grid

You can use Enterprise Manager to manage Sun Java Message Service Grid (JMS Grid) at runtime.


Note –

Enterprise Manager provides a unified management environment for Sun JMS IQ Manager, Sun Java System Message Queue, and Sun Java Message Service Grid (JMS Grid). However, the level of monitoring and management capabilities supported vary for the different message servers.


For basic information about Enterprise Manager, see Enterprise Manager Basics.

If the Project node in the left panel represents an application that uses JMS Grid destinations, then the Project node contains a subnode for each destination (for example, Queue1 and Queue2).

Monitoring Queues

You can use many of Enterprise Manager’s queue management options on the queues utilized by an application deployed in a server. This section describes these options and their level of support.

The top right panel displays information about the selected queue.

Table 1–3 Queue Tab - Columns

Column Name 

Description 

Queue Name 

The name of the queue. 

Min Sequence Number 

JMS Grid does not use sequence numbers, so this column always displays the value zero (0). 

Max Sequence Number 

JMS Grid does not use sequence numbers, so this column always displays the value zero (0). 

Available Count 

The number of unprocessed messages in the queue. 

Number of Receivers 

The number of receivers for this queue. 

Last Published Date/Time 

The date and timestamp of the most recent message currently available in the queue. If no messages are available, this column shows the last publication date and time of the last message. 

You can list the messages in a queue in the bottom right panel.

The following table describes the columns in the Messages tab.

Table 1–4 Message Tab Columns

Property Name 

Description 

Sequence Number 

The values in this column are hash values generated from the message ID and do not have meaning for JMS Grid. 

Message ID 

The unique identification number for the message. 

Status 

Indicates whether the message is unread. 

Message Size 

The size of the message including the JMS header (in bytes). 

Delivery Mode 

Indicates whether the message is persistent or nonpersistent. 

Priority 

The priority of the message from 0 to 9, with 9 as the highest priority. 

Sent On 

The day, date, and time when the message was received. 

The bottom right panel includes the following buttons:

The paging feature is not supported in this release. However, if you refresh the view, the list changes as messages are consumed and new messages are received.

Monitoring Topics

Enterprise Manager allows you to see an application’s topics in the left panel in a similar way to that illustrated for queues. The top right panel displays information about the selected topic.

Table 1–5 Topics Tab - Columns

Column Name 

Description 

Topic Name 

The name of the topic. 

Min Sequence Number 

JMS Grid does not use sequence numbers, so this column always displays the value zero (0). 

Max Sequence Number 

JMS Grid does not use sequence numbers, so this column always displays the value zero (0). 

Available Count 

The number of unprocessed messages in this topic. This value represents the number of messages which have not been consumed by any subscriber to the topic. 

Current Subscribers 

The number of subscribers who are actively consuming from the topic. 

Last Published Date/Time 

The date and timestamp of the most recent message currently available in the topic. If no messages are available, this column shows the last publication date and time of the last message. 

You can list the messages in a topic in the bottom right panel just as for queues. The column meanings for topics are the same as for queues. The messages might not be displayed in the order in which they were sent, as shown in the Sent On column.

This panel also has several buttons, whose functions are the same as for topics.

Monitoring Application Servers, Collaborations, and Alerts (Command Line)

The Enterprise Manager command-line client enables you to monitor application servers, Collaborations, and alerts.

The Enterprise Manager command-line client is located in the JavaCAPS-install-dir/emanager/em-client directory.

The Enterprise Manager command-line client provides two monitoring services:

The computer on which you run the command-line client must have Java 1.4.2 or later installed. In addition, the path variable must include an entry for the Java installation’s bin directory.


Note –

Do not include quotation marks in the value of the JAVA_HOME variable.


If you are running UNIX, then use the em-cmdline-client.sh script.

If you are running Windows, then use the em-cmdline-client.bat script.

Enterprise Manager Command-Line Client Syntax

The syntax of the Enterprise Manager command-line client is:


em-cmdline-client -l hostname -p port -u username -w password -s service 
-m method -Pparameter=value

The following table describes the arguments.

Table 1–6 Enterprise Manager Command-Line Client Arguments

Argument 

Description 

-h, --help 

Displays help about the command-line client. 

-l, --host 

Enables you to specify the hostname of the computer where Enterprise Manager is running. 

-p, --port 

Enables you to specify the base port number of Enterprise Manager. 

-u, --userid 

Enables you to specify an Enterprise Manager user name. 

-w, --password 

Enables you to specify the password for the Enterprise Manager user name. 

-s, --service 

Enables you to specify the service that you want to use. The runtime service is called RuntimeService51x. The alert service is called AlertService51x.

-m, --method 

Enables you to specify the method that you want to call. 

-P 

Enables you to specify a parameter name and value for a method. Some methods do not require parameters. 

-n, --signatures 

Displays the signatures of the available methods. 

-t, --timeout 

Enables you to specify an HTTP request timeout value for the command (in milliseconds). 

-v, --validate 

Checks for the required number of parameters. 

You use the following arguments to connect to the Enterprise Manager server: -l, -p, -u, and -w.

Monitoring Application Servers and Collaborations (Command Line)

You can monitor application servers and Collaborations by using the runtime service of the Enterprise Manager command-line client.

Before you begin, ensure that the Enterprise Manager server is running.

Set the -s argument to RuntimeService51x. Set the -m argument to the desired method. For each parameter, set the -P argument to the name and value.


Note –

The commands are shown on multiple lines for readability. You must enter the commands on a single line.


Listing the Available Methods For the Runtime Service

You can display a list of the available methods for the runtime service by using the -n argument. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x -n

 Note: the order of the parameters is important.
 Available methods and parameters:

-m getState -Pcomponent=<component> -PcomponentType=<componentType>
-m startComponent -Pcomponent=<component> -PcomponentType=<componentType>
-m getComponentsList
-m stopComponent -Pcomponent=<component> -PcomponentType=<componentType>
-m getStatus -Pcomponent=<component> -PcomponentType=<componentType>

Displaying the List of Components

The methods of the runtime service require you to specify the component path and component type. The getComponentsList method enables you to obtain this information. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x
-m getComponentsList

e51x|Servers|myserver:4848
is51x

e51x|Servers|myserver:4848|IQ_Manager_18007
stcms

e51x|Servers|myserver:4848|Sun_JMQ_7676
jmq

e51x|Servers|myserver:4848|Project1|Deployment1|CMap1|Service1
jce.JavaCollaborationDefinition

e51x|Servers|myserver:4848|Project1|Deployment1|CMap1|Service2
jce.JavaCollaborationDefinition

e51x|Servers|myserver:4848|Project1|Deployment1|CMap1|Topic1
messageService.Topic

Displaying the Current State

The getState method enables you to display the current state of an application server or Collaboration, as well as a JMS IQ Manager. You must specify the following parameters: the component path and the component type. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x
-m getState
-Pcomponent="e51x|Servers|myserver:4848"
-PcomponentType=is51x

Up

Viewing Basic Information

The getStatus method enables you to view basic information for an application server or Collaboration. You must specify the following parameters: the component path and the component type. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x
-m getStatus
-Pcomponent="e51x|Servers|myserver:4848"
-PcomponentType=is51x

HostAndPort = myserver:4848
Component = e51x|Servers|myserver:4848
System = e51x
RestartRequired = true

Starting and Stopping Collaborations

The startComponent method enables you to start a Collaboration. You must specify the following parameters: the component path and the component type. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x
-m startComponent
-Pcomponent="e51x|Servers|myserver:4848|Project1|Deployment1|CMap1|Service1"
-PcomponentType=jce.JavaCollaborationDefinition

The stopComponent method enables you to stop an application server domain, an application server instance, or a Collaboration. You must specify the following parameters: the component path and the component type. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s RuntimeService51x
-m stopComponent
-Pcomponent="e51x|Servers|myserver:4848|Project1|Deployment1|CMap1|Service1"
-PcomponentType=jce.JavaCollaborationDefinition

Note –

You cannot stop a message server with the stopComponent method.


The command line does not provide feedback to indicate that the method succeeded. However, you can verify whether the component is up or down by using the getState method.

Monitoring Alerts (Command Line)

You can monitor alerts by using the alert service of the Enterprise Manager command-line client.

Before you begin, ensure that the Enterprise Manager server is running.

Set the -s argument to AlertService51x. Set the -m argument to the desired method.


Note –

The commands are shown on multiple lines for readability. You must enter the commands on a single line.


Listing the Available Methods For the Alert Service

You can display a list of the available methods for the alert service by using the -n argument. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x -n

Note: the order of the parameters is important.
Available methods and parameters:

-m deleteAlerts -Pfilter=<filter>
-m getAllAlerts
-m observeAlerts -Pfilter=<filter>
-m resolveAlerts -Pfilter=<filter>
-m resolveAllAlerts
-m deleteAllAlerts
-m observeAllAlerts
-m getAlertQueryFields
-m getAlerts -Pfilter=<filter>
-m resetAlerts -Pfilter=<filter>
-m resetAllAlerts

Listing the Query Fields

The getAlertQueryFields method enables you to list the filters that you can use for the other methods. For example:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m getAlertQueryFields

from
to
id
environmentName
physicalHostName
logicalHostName
serverName
componentProjectPathName
deploymentName
componentName
severity
type
observationalState
operationalState
messageCode
details

Viewing Alerts

The getAlerts method enables you to display all of the alerts for the specified components. You can display a subset of the alerts by including one or more filters. The following example specifies two filters:


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m getAlerts
-Pfilter=componentProjectPathName=Project1;environmentName=Environment1
 
ID:10
Date:Wed Jun 04 15:56:58 PDT 2008
EnvironmentName:Environment1
LogicalHostName:LogicalHost1
ServerName:server
ComponentProjectPathName:Project1
DeploymentName:Deployment1
ComponentName:Service1
PhysicalHostName:myserver:4848
Severity:INFO
Type:COLLABORATION
ObservationalState:Unobserved
OperationalState:Running
MessageCode:COL-00001
Details: Collaboration jcdB is RUNNING

ID:9
Date:Wed Jun 04 15:56:57 PDT 2008
EnvironmentName:Environment1
LogicalHostName:LogicalHost1
ServerName:server
ComponentProjectPathName:Project1
DeploymentName:Deployment1
ComponentName:Service1
PhysicalHostName:myserver:4848
Severity:INFO
Type:COLLABORATION
ObservationalState:Unobserved
OperationalState:Running
MessageCode:COL-00001
Details: Collaboration jcdA is RUNNING

The getAllAlerts method enables you to display all of the alerts.

Changing the Status of Alerts

The initial status of an alert is Unobserved. You can change the status to Observed or Resolved. Observed means that you looked at and acknowledged the alert. Resolved means that you fixed the problem that caused the alert.

The observeAlerts method enables you to change the status of an alert to Observed.


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m observeAlerts
-Pfilter=componentProjectPathName=Project1;environmentName=Environment1

The observeAllAlerts method enables you to change the status of all alerts to Observed.

The resolveAlerts method enables you to change the status of an alert to Resolved.


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m resolveAlerts
-Pfilter=componentProjectPathName=Project1;environmentName=Environment1

The resolveAllAlerts method enables you to change the status of all alerts to Resolved.

The resetAlerts method enables you to change the status of an alert to the initial value (Unobserved).


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m resetAlerts
-Pfilter=componentProjectPathName=Project1;environmentName=Environment1

The resetAllAlerts method enables you to change the status of all alerts to the initial value (Unobserved).

Deleting Alerts

The deleteAlerts method enables you to delete alerts.


em-cmdline-client -l entmgrhost -p 15000 -u Administrator -w STC
-s AlertService51x
-m deleteAlerts
-Pfilter=componentProjectPathName=Project1;environmentName=Environment1

The deleteAllAlerts method enables you to delete all alerts.