How to delete a rule from the command line?
To follow the steps below, you need to know the rule ID. The ID can be found in the MonitoringPolicies_<timestamp>.xml file which is part of the support bundle. Search for the rule name and you will get the ID - example:
Download the attached script "deleterule.groovy"
Copy it to the Foglight server into folder FMSHOME/bin directory
Open the command line and execute the following:
fglcmd -usr <username> -pwd <password> -cmd script:run -f deleterule.groovy <ruleid>
Example:
C:\Quest_Software\Foglight\bin>fglcmd -usr foglight -pwd foglight -cmd script:run -f deleterule.groovy 3e18d884-6824-447d-a02c-f8c554922309
Please replace user and password with your user and password.
Once you delete the rule via script, it will disappear from the Foglight UI.
© ALL RIGHTS RESERVED. Terms of Use Privacy Cookie Preference Center