Submit a ticketCall us

Don’t fall victim to a ransomware attack
Backups are helpful, but sometimes that’s not enough to protect your business against ransomware. At our live webcast we will discuss how to protect against ransomware attacks with SolarWinds® Patch Manager and how to leverage log data to detect ransomware. Register now for our live webcast.

Home > Success Center > Server & Application Monitor (SAM) > General information on how to debug script monitors

General information on how to debug script monitors

Table of contents
Created by Chris Foley, last modified by MindTouch on Jun 23, 2016

Views: 77 Votes: 1 Revisions: 3

Overview

This article provides some tips on troubleshooting issues with SAM's script monitors.

Environment

  • All versions of SAM
  • All versions of Windows
  • All versions of Linux

Steps

Generally there are two ways to help you isolate an issue with running a script via a Script Monitor (Windows Script Monitor, Windows Powershell Monitor or Linux/Unix Script Monitor):

 

1. Use the Get Script Output feature.
    a. Go to Settings > SAM Settings > Manage Applications.
    b. Select the Application that contains your script and click Edit Properties.
    c. Open the Script Monitor.
    d. Next to Script body, click Override Template.
    e. Click Edit Script.
    f. Click Get Script Output.

 

This should provide the error being returned by the script or if the monitor is misconfigured.

2. Enable debug on the Application.
    a. On the settings page for the Application, open the Advanced section.
    b. Set the Debug logging to ON. 
    c. Click Save and Continue working.
    d. Select the component and click test.
    e. Open the Application Debug log file in the following directory:
C:\ProgramData\Solarwinds\Logs\APM\ApplicationLogs\AppId[##]\

Note: ## is the internal ID of the Application, as seen in the Browser's address bar when viewing the Application's settings.
This log should provide information on the script run and the response received

 

 

 

Last modified
02:53, 23 Jun 2016

Tags

Classifications

Public