Run Probe Commands from a Command Prompt

Use the Probe Utility (pu) command to run probe commands from a command prompt. This utility is useful for running scripts to complete repetitive tasks (such as deleting multiple probes or multiple instances of a probe) or to avoid navigating through multiple levels of a user interface to complete an action. You must have a valid username and password to run commands.
uim901
Use the 
Probe Utility (pu)
 command to run probe commands from a command prompt. This utility is useful for running scripts to complete repetitive tasks (such as deleting multiple probes or multiple instances of a probe) or to avoid navigating through multiple levels of a user interface to complete an action. You must have a valid username and password to run commands.
PU is shipped as a separate package you install from the archive.
The command has the following format:
     $UIM_HOME
/bin/pu -u 
<username
> -p 
<password> <options> <nim_address
> <
probe command> <data>
 
  •  
     -
    u
     
    <username
    - The UIM user name
  •  
     
    -p  <password>
     
    - The UIM password
  •  
     
    <nim_address>
     
     - The UIM address of the probe in the form 
    /domain/hub/robot/probe
     
  •  
     
    <probe command>
     
    - The command to execute
The following example executes the 
get_info
 command on the CDM Probe at 
/Dev_domain/Dev_hub/Dev_robot
. The user name is 
rune
, and the password is 
1234admin
.
     
$UIM_HOME
/bin/pu -u rune -p 1234admin /Dev_domain/Dev_hub/Dev_robot/cdm get_info 
List Commands Available for a Probe
The commands available for a probe differ for each probe. Use the pu command to list the commands available for a probe.
     $UIM_HOME
/bin/pu -u 
<username>
 -p 
<password>
 </domain/hub/robot/probe> 
The controller probe contains many commands to control other probes. To list the commands that are available from the controller probe:
     
$UIM_HOME
/bin/pu -u 
<username>
 -p 
<password>
 /Dev_domain/Dev_hub/Dev_robot/controller 
A partial example of the return:
Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.
C:\Program Files (x86)\Nimsoft\bin>pu.exe -u administrator -p ***** /Dev_domain/Dev_hub/Dev_robot/controller
Nov 8 17:06:18:278 pu: SSL - init: mode=0, cipher=DEFAULT, context=OK
Nov 8 17:06:18:279 pu: nimCharsetSet() - charset=
======================================================
Address: /Dev_domain/Dev_hub/Dev_robot/controller Request: _command
======================================================
_status PDS_PCH 9 detail%d
_command PDS_PCH 9 detail%d
_debug PDS_PCH 40 level%d,trunc_size%d,trunc_time%d,now%d
~
_stop PDS_PCH 0 NULL
_restart PDS_PCH 0 NULL
checkin PDS_PCH 14 hubaddr,hubip
probe_checkin PDS_PCH 7 type%d
iptoname PDS_PCH 10 ip,port%d
nametoip PDS_PCH 5 name
login PDS_PCH 7 type%d
verify_login PDS_PCH 0 NULL
change_password PDS_PCH 0 NULL
probe_list PDS_PCH 11 name,robot
probe_register PDS_PCH 113 name,active,type,timespec,command,arguments,
workdir,config,datafile,logfile,description,group,fail_window,realip
~
probe_unregister PDS_PCH 15 name,noforce%d
probe_activate PDS_PCH 5 name
probe_deactivate PDS_PCH 29 name,noforce%d,waitforstop%d
probe_store PDS_PCH 9 filename
probe_config_lock PDS_PCH 31 name,locktype%d,lockid%d,robot
~
probe_config_lock_list PDS_PCH 5 name
probe_config_get PDS_PCH 15 name,robot,var
probe_config_set PDS_PCH 38 name,section,key,value,lockid%d,robot
~
probe_set_port PDS_PCH 18 name,port%d,pid%d
probe_start PDS_PCH 5 name
probe_stop PDS_PCH 5 name
probe_change_par PDS_PCH 15 name,par,value
probe_tail_logfile PDS_PCH 26 name,size%d,prev_record%d
probe_tail_logfile_session PDS_PCH 31 name,max_buffer%d,from_start%d
...
Set a Key-Value Pair
You can use the pu command to set probe key-value pairs. Use the following command format to set a key-value pair for a probe.
     
$UIM_HOME
/bin/pu -u <
username
> -p <
password
> controller probe_config_set <
probe name
> <
config file section
> <
key
> <
value
> lockid = "" <
robot
  •  
    -
    u
     
    <username
    - The UIM user name
  •  
     
    -p  <password>
     
    - The UIM password
  •  
     
    <probe name>
     
     - The name of the probe
  •  
     
    <config file section> 
     
     
    The fully qualified name of the configuration section, for example, 
    /auto_operator/definitions/Email
     
  •  
     
    <key> 
    The key to change
  •  
     
    <value> 
    The new value for the key
  •  
     
    <robot>
     
     - The fully qualified name of the robot controlling the probe, for example, 
    /my_domain/my_hub/my_robot
     
Reread the probe configuration file for changes to take effect.
The following example updates the 
active 
value to 
yes 
for the auto-operator that is named 
methodName 
in the nas configuration file. 
$UIM_HOME
/bin/pu -u administrator -p password controller probe_config_set nas /auto_operator/definitions/methodName active yes "" /Dev_domain/Dev_hub/Dev_robot
Reread the nas configuration file using the 
_restart
 command.
$UIM_HOME
/bin/pu -u administrator -p password /Dev_domain/Dev_hub/Dev_robot/nas _restart
Commands return a completion message for actions as appropriate.