Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Update for PDF export

...

Alert levels are defined as follows:

Days before expiration (date limited license)Hours before expiration (time limited license)Alert Level
More than 7More than 72 hoursINFORMATIONAL
Between 4 and 7Between 49 and 72 hoursMINOR
Between 2 and 3Between 25 and 48 hoursMAJOR
Less than 2Between 0 and 24 hoursCRITICAL
< 00 hours and 0 minutes
Highlight
color#FF0000

EXPIRED

Example

Command line parameters

...

Example (command executed on 0921-Jul-2020):

# /opt/charon/utils/charon_expchk 15 -nomail -expdat=1224-Jul-2020

...


The command above, with forced expiration date, will provide the following results:

...

  • $1 = level that can be (case sensitive): Informational, Minor, MAJOR, CRITICAL, EXPIRED or NEUTRAL
    • Note: NEUTRAL is sent when no alert is detected, used to send counter alert.
  • $2 = message starting with ":" followed by the license expiration date, the license number and the product.
    • Example: : 1224-Jul-2020. License: 1001687. Product: CHARON-AXP

...

Script example using Zabbix software:

...


Div

...

classsmall

#!/bin/sh

...


#-------------------------------------------------------------------------------

...


#

...

charon_expchk.custom

...


#-------------------------------------------------------------------------------

...


ZABSEND=/usr/bin/zabbix_sender

...


ZABCONF=/etc/zabbix/zabbix_agentd.conf

...

if

...

test

...

-x

...

${ZABSEND}

...


then
  if test -s

...

${ZABCONF}

...


  then
    case "$1"

...


    in
      Informational) LVL="INFORMATION";;

...


      Minor) LVL="WARNING";;

...


      MAJOR) LVL="AVERAGE";;

...


      CRITICAL) LVL="HIGH";;

...


      EXPIRED) LVL="DISASTER";;

...


      *) LVL="NEUTRAL";;

...


    esac
    ${ZABSEND}

...

-c

...

${ZABCONF}

...

-k

...

charon_expchk

...

-o

...

"${LVL};$2"

...

>/dev/null

...


  else
    echo "The

...

Zabbix

...

agent

...

configuration

...

file

...

is

...

missing.

...

Cannot

...

send

...

alert!"

...


  fi
fi


Include Page
KBCOMMON:DOC-GoToToc
KBCOMMON:DOC-GoToToc