This pair of scripts, one to be installed on the NetMRI to be run in its sand box (API Example - send command.pl) and one to be run remotely on customer hardware (remote_send_command.pl) allows a user to send commands to devices managed by the NetMRI using the NetMRI Job Engine as a proxy.
1. Log into the GUI of the NetMRI using your web browser
2. Navigate to Configuration Management -> Job Management -> Scripts
3. Click on the “Import” button in the lower right hand corner
4. Specify the attached file “API Example -send_command.txt”
5. Click on “Import”
6. From your external Perl environment run “perl remote_send_command.pl devicename command”
7. For example if you want to send the “show command” to device “foo.example.com” you would use “perl remote_send_command.pl foo.example.com show device”
The example provided creates a session for each command that you send from the remote script, although the example could be extended to execute multiple commands per run of the NetMRI Perl Script, or more complicated logic could be included in the NetMRI Perl script which runs on the NetMRI.