Forum Discussion
Simon_Blakely
Nov 01, 2020Employee
You need to understand the behaviour of External monitors and stdout
K7444: Requirements for external monitor output
-----
Custom external monitors must observe the following output requirements:
- If a server meets the external monitor criteria, the external monitor must send data to stdout.
- Note: Any data on stdout results in an Available status. The data does not have to be specific to the condition of the server.
- Note: Any standard output stops the script from running. To ensure that the necessary operations occur, F5 recommends that you clean up any temporary files, perform logging, etc., before the system performs the standard output operation.
- If a server fails to meet the external monitor criteria, the external monitor must not send any data to stdout.
-----
Looking at your script, you have
status=$?
echo "$status"
This will terminate the script here, and mark the monitor as "Available".
If you need to log something from the script for development purposes, use *logger* to log into /var/log/ltm