Script:
Clean Up Cisco Debug commands
Script-Description:
This script executes a show debug command, and if any debug
commands are running, issues a 'no debug all' and opens a NetMRI
issue stating the debug commands that were running.
Script-Filter:
$Vendor eq "Cisco"
and $Type eq "Router"
#Script-Schedule:
# 15 2 * * 1-5
Script-Groups:
Routing
#######################################################################
Action:
Show Debug
Action-Description:
Execute the "show debug" command.
Action-Commands:
show debug
Output-Triggers:
Process debug
#######################################################################
Trigger:
Process debug
Trigger-Description:
Determine which interfaces have debugging turned 'on', from the above output,
and turn the debugging off by issuing the command "no debug all".
Trigger-Variables:
$ifDebug string
Trigger-Template:
[[$ifDebug]] is on.*
Trigger-Commands:
DEBUG: no debug all
Output-Triggers:
Debug Left Running
#######################################################################
Issue:
Debug Left Running
Issue-ID:
DebugLeftRunning
Issue-Severity:
Error
Issue-Description:
The following devices had debugging left "on"
Issue-Filter:
true
Issue-Details:
Host $IPAddress
Name $Name
ifdebug $ifDebug
#######################################################################