You can use Junos Space Network Management Platform to
trigger the execution of op scripts on one or more devices simultaneously.
Commit and event scripts are automatically activated after they are
enabled. Commit scripts are triggered every time a commit is called
on the device and event scripts are triggered every time an event
occurs on the device or if a time is specified.
You can execute a script on the physical interfaces of one device
or multiple devices.
Note: You can execute scrips on more than 200 devices only if
the scripts do not require XPath processing. Scripts that do not require
XPath processing include scripts without device-specific or entity-specific
parameters and with /, //, or /device as context.
To execute a script on the physical interfaces:
- On the Junos Space Network Management Platform user interface,
select Devices > Device Management.
The Device Management page is displayed.
- Select the device (or multiple devices) and select Device Inventory > View Physical Interfaces from
the Actions menu.
The View Physical Interfaces page is displayed.
- Right-click the physical interfaces on which the script
has to be executed and select Execute Scripts.
The Execute Scripts page displays the following scripts:
Scripts that are associated with and enabled (device scripts)
on the selected devices
Scripts whose execution type matches your selection. If
you selected multiple devices, only scripts whose EXECUTIONTYPE is
set to GROUPEDEXECUTION are displayed. If you selected a single device,
scripts whose EXECUTIONTYPE is set to SINGLEEXECUTION and GROUPEDEXECUTION
are displayed.
Scripts whose context matches the physical interface context
The Execute Scripts Page in
the Devices Workspace table lists the columns on the Execute
Scripts page and their descriptions.
- Select the script that you want to execute on the physical
interfaces manually or by using tags.
To select the script manually:
Click the Select Manually option button.
This option button is selected by default.
Select the script.
To select the script by using tags:
Click the Select by tags option button.
From the Select by tags drop-down list, select
an appropriate tag.
Click OK.
The list of scripts is further filtered by the tag you selected.
Select the script.
- (Optional) To enter the values for the parameters of the
script, click the appropriate cell in the Value column.
If you enter a value for a parameter that is a Password
field, the value you enter is hidden.
If you enter a value for a parameter that is a Confirm
Password field, a pop-up window is displayed. Enter the password again
and click OK.
- Select whether to execute the script now or schedule
the execution for a later time:
To execute the script on the physical interfaces now:
Click Execute.
The Script Results page appears. The Script Results Page table lists the columns and their
descriptions.
The lower area of the Script Results page displays the results
of the script execution. If you executed a local script that contains
the GROUPBYDEVICE annotation set to TRUE on the physical interfaces
of multiple devices, click the appropriate device in the Device Name
column to view the script execution results on the physical interface
of the device.
Click Close (at the bottom of the page).
You are redirected to the View Physical Interfaces page.
Click Back (at the top-left corner) to return
to the Device Management page.
To schedule the execution of the script on the physical
interfaces for a later time:
Select the Schedule at a later time check box.
Enter the date in the Date field in the MM/DD/YYYY
format.
Enter the time in the Time field in the hh:mm
format.
Click Execute.
The Job Information dialog box displays a link to the job ID.
Click the Job ID link to view the status of this
task on the Job Management page.
Click OK to close the Job Information dialog
box.
You are redirected to the View Physical Interfaces page.
Click Back (at the top-left corner) to return
to the Device Management page.