Tags:
, view all tags

CEMon CLI User guide

1 Introduction

The CEMon CLI is provided by the glite-ce-monitor-client-api-c package, which is installed by default on a EMI-UI.

It provides the following executables:

  • /usr/bin/glite-ce-monitor-getinfo
  • /usr/bin/glite-ce-monitor-gettopics
  • /usr/bin/glite-ce-monitor-getevent

/usr/bin/glite-ce-monitor-consumer

/usr/bin/glite-ce-monitor-pause
/usr/bin/glite-ce-monitor-resume
/usr/bin/glite-ce-monitor-subinfo
/usr/bin/glite-ce-monitor-subscribe
/usr/bin/glite-ce-monitor-subupdate
/usr/bin/glite-ce-monitor-unsubscribe

whose use is explained in the following sections.

2 Query the CEMon service

2.1 Get general information about CEMon

glite-ce-monitor-getinfo is the tool to be used to have general information about a CEMon installation.

Usage:

glite-ce-monitor-getinfo [--cert <CERTIFICATE_FILE] [--key <KEY_FILE>] <CEMon_URL> 

If the --cert option is not specified, the file referred by the environment variable X509_USER_CERT is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

If the --key option is not specified, the file referred by the environment variable X509_USER_KEY is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

CEMon_URL is the URL of the CEMon service

Example:

$ glite-ce-monitor-getinfo --cert /tmp/x509up_u756 --key /tmp/x509up_u756 https://cream-35.pd.infn.it:8443/ce-monitor/services/CEMonitor
Description=[cemonitor service]
Version    =[1.0]
HostDN     =[/C=IT/O=INFN/OU=Host/L=Padova/CN=cream-35.pd.infn.it]
Action [SendExpiredNotification::]
Action [DoNotSendNotification::]
Action [SendNotification::]

2.2 Get information about deployed CEMon sensors

glite-ce-monitor-gettopics is the tool to be used to have general information about installed CEMon sensors. For each installed sensor it provides:

  • the topic name
  • the available dialects, along with the query languages that can be used for that dialect

Usage:

glite-ce-monitor-gettopics [--cert <CERTIFICATE_FILE] [--key <KEY_FILE>] <CEMon_URL> 

If the --cert option is not specified, the file referred by the environment variable X509_USER_CERT is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

If the --key option is not specified, the file referred by the environment variable X509_USER_KEY is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

CEMon_URL is the URL of the CEMon service

Example:

$ glite-ce-monitor-gettopics --cert /tmp/x509up_u756 --key /tmp/x509up_u756 https://cream-35.pd.infn.it:8443/ce-monitor/services/CEMonitor
Topic [CE_MONITOR]
   Dialect [ISM_CLASSAD_GLUE_1.2]
      queryLanguage [RegEx]
      queryLanguage [ClassAd]
   Dialect [ISM_CLASSAD]
      queryLanguage [RegEx]
      queryLanguage [ClassAd]
   Dialect [ISM_LDIF_GLUE_1.2]
      queryLanguage [RegEx]
      queryLanguage [ClassAd]
   Dialect [ISM_LDIF]
      queryLanguage [RegEx]
      queryLanguage [ClassAd]
Topic [CREAM_JOBS]
   Dialect [CLASSAD]
      queryLanguage [ClassAd]

2.3 Get information provided by a CEMon sensor

glite-ce-monitor-getevent is the tool to be used to get the last output produced by a specific CEMon sensor

Usage:

glite-ce-monitor-getevent --topic <TOPIC_NAME> [--dialect <DIALECT_NAME>] [--cert <CERTIFICATE_FILE>] [--key <KEY_FILE>] <CEMon_URL

TOPIC_NAME is the name of the topic (sensor) for which the event is requested

=DIALECT_NAME is the name of the dialect (which defines how the information should be rendered). ==If the --dialect option is not specified the default dialect for that sensor is considered

If the --cert option is not specified, the file referred by the environment variable X509_USER_CERT is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

If the --key option is not specified, the file referred by the environment variable X509_USER_KEY is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

CEMon_URL is the URL of the CEMon service

Example:

$ glite-ce-monitor-getevent --topic CE_MONITOR --dialect ISM_LDIF --cert /tmp/x509up_u756 --key /tmp/x509up_u756 https://cream-35.pd.infn.it:8443/ce-monitor/services/CEMonitor | more
Event[0]:
   Message[0]=[[
   gluecestatefreejobslots = 0;
   glueceinfolrmstype = "lsf";
   gluecestatetotaljobs = 0;
   gluecepolicymaxtotaljobs = 999999999;
   glueceinfocontactstring = "https://cream-35.pd.infn.it:8443/ce-cream/services";
   gluecepolicypreemption = 0;
   glueforeignkey = {
      "GlueClusterUniqueID=cream-35.pd.infn.it" 
   };
   gluecestaterunningjobs = 0;
   gluecestateestimatedresponsetime = 777777;
   gluecepolicymaxobtainablewallclocktime = 999999999;
   glueinformationserviceurl = "ldap://cream-35.pd.infn.it:2170/mds-vo-name=resourc";
   glueceinfodatadir = "unset";
   gluecehostingcluster = "cream-35.pd.infn.it";
   gluecepolicymaxwaitingjobs = 999999999;
   gluecestateworstresponsetime = 1555554;
   glueceinfoapplicationdir = "/opt/exp_soft/alice";
   glueceuniqueid = "cream-35.pd.infn.it:8443/cream-lsf-creamtest2";
   glueceimplementationversion = 31;
   gluececapability = "unset";
        ...
        ...

3 Work with CEMon subscriptions

3.1 Create a subscription

glite-ce-monitor-subscribe is the tool to be used to create a CEMon subscription. The events produced by the relevant CEMon sensor will be specified to the specified CEMon consumer.

Usage:

glite-ce-monitor-subscribe [--cert <CERTIFICATE_FILE>] [--key <KEY_FILE>] --topic <TOPIC_NAME> [--dialects <COLON-SEPARATED_DIALECT_LIST>] --consumer-url <CONSUMER_URL_TO_SUBSCRIBE> [--rate <DELAY_BETWEEN_TWO_NOTIFICATIONS>] [--duration <DURATION_OF_SUBSCRIPTION>] <CEMon_URL>

If the --cert option is not specified, the file referred by the environment variable X509_USER_CERT is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

If the --key option is not specified, the file referred by the environment variable X509_USER_KEY is considered. If this variable is not set, the the file referred by the environment variable X509_USER_PROXY is considered. If even this variable is not set, the file /tmp/x509_u<uid> is considered

TOPIC_NAME is the name of the topic (sensor) for which the event is requested

If the --dialects option is not specified the default dialect for that sensor is considered

CONSUMER_URL_TO_SUBSCRIBE is the URL of the CEMon consumer where the information produced by the relevant CEMon sensor must be sent

Notifications for the specified topic will be sent to the consumer every DELAY_BETWEEN_TWO_NOTIFICATIONS seconds

Example:

$ glite-ce-monitor-subscribe --topic CE_MONITOR --dialects ISM_LDIF --cert /tmp/x509up_u756 --key /tmp/x509up_u756 --consumer-url http://lxsgaravatto.pd.infn.it:5676 https://cream-35.pd.infn.it:8443/ce-monitor/services/CEMonitor
SubscriptionID=[uuid-1247573738304]


-- MassimoSgaravatto - 2011-04-20

Edit | Attach | PDF | History: r3 < r2 < r1 | Backlinks | Raw View | More topic actions...
Topic revision: r1 - 2011-04-20 - MassimoSgaravatto
 
  • Edit
  • Attach
This site is powered by the TWiki collaboration platformCopyright © 2008-2020 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback