What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags

View all Tags

Simple Sensor to query SQL error log strings



we want to monitor failures of the backup jobs running at a SQL server instance. For now we set the sp_readerrorlog procedure as a starting point to get the information from the log.

EXEC sp_readerrorlog 0, 1, 'flush', 'failure'

This is an example how the procedure output look like: 215 | 2021-06-25 13:331:02.750 | spid59 | BackupVirtualDeviceFile: RequestDurableMedia: Flush failure in device 'EMC#ea45d....'

Question is, does an easy solution exists within PRTG to throw a notification when the above "fail" strings are detected?

prtg query read-error-log sql

Created on Jun 28, 2021 10:14:37 AM

1 Reply




I assume that the string changes over time (since it contains a time and date). If that is the case, then you will not be able to monitor the result, since the SQL sensor can not perform a string search.

There is a workaround that would allow you to show strings in a SQL sensor, however this works only if you have a limited number of strings and they are always the same.
More information about this can be found here.

If you can perform the string search in the procedure, and return a numeric value as a result (0 for sting not found, 1 for string found), I would recommend to use that.
A other alternative would be to create a custom script that would do the string search and run it with one of our custom sensors.

Kind regards,
Sasa Ignjatovic, Tech Support Team

Created on Jun 30, 2021 7:55:50 AM by  Sasa Ignjatovic [Paessler Support]

Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.