Add a scripting task that SolarWinds N-central runs at a scheduled time. You can select a script from the SolarWinds N-central repository or upload a script from your local system. Scripts can be one of:
- batch file (.bat)
- PowerShell (.ps1)
- Visual Basic (.vbs, .vb, or .vbe)
Script file names must not contain spaces. Ensure that PowerShell is installed on the target devices before running PowerShell scripts.
When running a script whose name contains spaces, you need to enclose the script name in quotes.
This procedure can only be performed at the Service Organization level or Customer level.
- Click Configuration > Scheduled Tasks > Add/Delete.
- Click Add > Scripting.
- Enter a Task Name.
- Select the security Credentials of the account that will be used to run the automation policy.
- Select the location where the script is stored from the drop-down menu and complete the additional scripting details.
- Click the Task Handler tab and select whether the agent or probe handles the script.
- Click the Targets tab and selected the devices targeted for the policy task by selecting specific devices or using a filter.
- Click the Schedule tab and set a time when SolarWinds N-central runs the task.
- In the Missed Executions options configure how far in the future SolarWinds N-central should take action on a device that is currently offline, and how long it should wait, once the device powers on, before running the scheduled task.
- On a recurring task, you can also set the task not to run the scheduled task if the next occurrence of the task will be launched near the time of the recurring schedule, to avoid conflicting task windows.
The scheduled task is saved to the repository. SolarWinds N-central runs the task at the configured time. When complete, and if configured to do so, SolarWinds N-central sends a notification to the selected recipients in the format defined by their user profile.
If you choose to edit the task, the edits may not be applied to the task if it has been initiated. Edits are applied to completed tasks only if they are recurring tasks.
- SolarWinds N-central does not verify syntax and command line parameters of scripts or MSI/EXE installers to ensure that they are correct. You must validate scripts and MSI/EXE installers before using them in scheduled tasks to ensure that they will function properly.
Command line parameters for MSI installers must be in the format of: <filename> </i or /u> </additional parameters>. For example, MyInstaller.msi /i /qn. The following examples are invalid: MyInstaller.msi /qn or /i MyInstaller.msi /qn.
- If execution of a script requires user input, it must be specified in the Command Line Parameters field when the task is created.
- SolarWinds N-central provides a combined total of 500 MB of storage for the script and software repositories.