One method of restarting a probe on an interval involves the use of the nas probe with a script that is run on a scheduled interval. The following steps outline how to perform this action using the nas.
Creating the script
- Open the nas GUI
- Click the Auto-Operator tab
- Click the Scripts sub-tab
- Right click in the file list window and and choose New -> Script
- Use the following code template, replacing "addr" and "probe" with actual values from your environment and save it.
addr = "/domain/hub/robot/controller"-- Build Nimsoft address for robot whose probe needs to be restarted
probe = "<probe_name>"-- specify the probe to be restarted
local args = pds.create()-- create data structure to pass arguments to probe callbacks
pds.putString(args,"name",probe)
nimbus.request(addr,"probe_deactivate",args)
sleep(40000)-- 40 seconds delay between deactivating and activating the probe
nimbus.request(addr,"probe_activate",args)
pds.delete(args)
Creating the schedule
- Click the Scheduler sub-tab
- Right click in the schedule list window and choose New
- Set Mode to "By Recurring Event"
- Set Operation to "Execute Script"
- Set the Start at date to a date in the past
- Set the time section to a starting time that is applicable to your needs
- Set Pattern to an interval period that is applicable to your needs
- Choose your script from the Script dropdown
- Click OK
- Enter a name for the schedule
- Right click on the schedule and click Activate
- Click Apply and Yes to restart the nas probe