Description
The attached Windows executable (installer, C# source, and Visual Studio project included) will unmanage/remanage/suppress/resume alerts for either a single node or for all members of a Solarwinds group. If run against a group, the program will unmanage* or mute** all items in the group (Nodes, Applications, Transaction, etc.). If the group includes sub-groups, the script will recursively handle them. Credentials are stored in an encrypted file.
*Only Solarwinds entities that can be unmanaged. Some entities, such as Volume and Transaction Step entities, are inherently un-unmanageable.
** Any Solarwinds entity can be muted.
Run from Windows Task Scheduler
To run this script from the Windows task scheduler without including the username and password on the command line follow the steps below:
- Log in to the Task Scheduler server as the user under whose name the task will run.
- Run the program with the --credentials flag to save credentials.
- Start the Task Scheduler and create a task to run the script. Open the properties.
- In the "General" tab, configure the task to run as the user you logged in as in step 1.
- Save the task.
Syntax
SWUnmanage.exe -S <Server> [-H <Nodename> | -G <Groupname>] [-m | -n] -D -t <Duration> [-d]
SWUnmanage.exe -S <Server> [-H <Nodename> | -G <Groupname>] [-m | -n] [-d]
SWUnmanage.exe -h
SWUnmanage.exe --credentials
SWUnmanage.exe --version
Command line parameters
-S <Server>, --server <Server> IP or FQDN of Solarwinds server.
-H <Nodename>, --hostname <Nodename> Name of the node (VM or server) that should be (un)managed or (un)notified.
-G <Groupname>, --group <Groupname> Name of the group that should be (un)managed or (un)notified.
-t <Duration>, --time <Duration> Duration of the unmanaged period in minutes. [default: 60]
-n, --notification Enable or disable NOTIFICATIONS for the specified nodes.
-m, --management Enable or disable MANAGEMENT for the specified nodes.
-D, --disable DISABLE management/notifications for the specified nodes.
-d, --debug Display debug output.
-h, --help Show this message.
--credentials Prompt for new Solarwinds credentials to be encrypted and saved.
--version Show the program version.
Examples
Example 1
Set credentials (program will prompt for username and password)
SWUnmanage.exe --credentials
Example 2
Unmanage the group "Prd_Servers" for 1 hour
SWUnmanage.exe -S solarwinds.domain.com -G Prd_Servers -D -m -t 60
Example 3
Remanage the group "Prd_Servers"
SWUnmanage.exe --server solarwinds.domain.com --group Prd_Servers --management
Example 4
Mute the node "POLLER01.domain.com" for 10 minutes
SWUnmanage.exe -S solarwinds.domain.com -H POLLER01.domain.com -n -t 10 -D