You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Introduction

For Agents a Watchdog Script is provided that serves the purpose to

  • start and restart the Agent,
  • terminate child processes if an Agent is crashed,
  • provide logging.

Watchdog Script

The Watchdog Script is provided for Unix and Windows. It is not used when operating the Agent from a Windows Service.

The Watchdog Script is available from the following location:

  • Unix
    • <agent-home>/bin/watchdog.sh
  • Windows
    • <agent-home>\bin\watchdog.cmd

Starting Agent / Restarting Agent

Technically the Watchdog Script is used to start the Agent from its agent.sh|.cmd Start Script.

In the following situation the Watchdog Script will restart the Agent:

  • For the command line operation: agent.sh|.cmd restart

Terminating Processes after Crash

In a situation when the Agent gets crashed, users might find a number of processes and related child processes running for jobs. Such processes continue to run which is undesired behavior as the outcome of jobs and execution results would not be known.

The Agent keeps track of processes and child processes created for jobs. The Watchdog Script will pick up this information and will

  • send all processes and child processes created by the Agent the SIGTERM signal,
  • wait for the period specified with the --sigkill-delay option of the Agent Start Script, see JS7 - Agent Command Line Operation.
  • send remaining processes and child processes the SIGKILL signal.

FEATURE AVAILABILITY STARTING FROM RELEASE 2.7.2

JS-2148 - Getting issue details... STATUS

Logging

The Watchdog Script will capture output to the stdout/stderr channels through the lifetime of an Agent.

Log output is stored to the <agent-data>/logs/watchdog.log file.

  • The log file reports the command line used to start the Agent.
  • The log file holds information about use of a JS7 - License.
  • The log file is an important source for analyzing problems:
    • Any warnings and errors that will not make it for Log4j logging is reported to the log file.
    • The same applies to warnings and errors that occur before the JVM is initialized and before Log4j logging can start, for example if an incomptible Java version is used when starting the Agent.



  • No labels