ADC

Configure a user monitor

User monitors track the health of custom applications and protocols that a Citrix ADC appliance does not support. This is an extended scope of custom monitors. To configure a user monitor, you must perform the following steps:

  • Write a script that can monitor the services bound to it.
  • Upload the script to the/nsconfig/monitorsdirectory on the Citrix ADC appliance.
  • Provide executable permission to the script.

If the monitor type is a protocol that the appliance does not support, only then you must use a monitor of type用户。用户监控只支持Perl和Bash sc型ripts. They do not support Python scripts.

Note

Monitor probes originate from the NSIP address. Thescriptargsconfigured for the monitor type用户is displayed in the running configuration and ns.conf files.

For more information about monitors, seeConfigure monitors

To configure a user monitor by using the CLI

At the command prompt, type:

add lb monitor  USER -scriptname  -scriptargs  -secureargs  

Example1:

add monitor Monitor-User-1 USER -scriptname nsftp.pl -scriptargs "file=/home/user/ sample.txt;user=root;password=passwd" 

Example2:

add monitor Monitor-User-1 USER -scriptname nsftp.pl -scriptargs "file=/home/user/ sample.txt -secureargs "user=root;password=passwd" 

Note

Thesecureargsparameter stores the script arguments in an encrypted format instead of the plain text format. Citrix recommends you use thesecureargs参数而不是scriptargs参数any sensitive data that is related to the scripts, for example, user name and password. If you choose to use both the parameters together, the script specified in-scriptnamemust accept the arguments in the order: 。Specify the first few arguments in theparameter; and the rest of the arguments in theparameter. That is, maintain the order defined for the arguments. Secure arguments are applicable only for the internal dispatcher. If you want to use an external dispatcher, Citrix recommends securing the vulnerable data in your scripts.

Example 3:

Let’s say you have already configured thescriptargsparameter with the arguments: “a=b;c=d;e=f”.

add monitor mon1 USER -scriptargs "a=b;c=d;e=f" 

If you want to use thesecureargsparameter instead ofscriptargsparameter, do the following:

  • Nullify thescriptargsparameter.
  • Provide all the arguments undersecureargsparameter.
set monitor mon1 USER -scriptargs "" -secureargs "a=b;c=d;e=f" 

To configure a user monitor by using the GUI

  1. Navigate toTraffic Management> Load Balancing> Monitors, clickAdd
  2. In theCreate monitorpage, do the following:
    • 选择监控类型用户
    • Choose the script from the drop-down menu or upload your own script.
    • Enter appropriate values for theScript ArgumentsandSecure Argumentsfields.
    • ClickCreate

    A user monitor is created.

Configure a user monitor