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

regular expression case sensitive

Votes:

0

Hello,

I would like to use the sensor IMAP for various backup solutions. That's why I have the following regular expression in use:

\b(error|alarm|warning|critical|fehler|error|failed|achtung)\b/ig

This also works as long as the words are lowercase. Problems are here, e.g. "Fehler" or "ERROR". Is "/ig" not correct to disable case sensitive?

Gerard

backup-monitoring imap regular-expression

Created on Mar 24, 2019 3:50:19 PM



1 Reply

Votes:

0

Hi Gerard,

Thanks for the question. Unfortunately, PRTG doesn't support regex options, I've tripped over that as well in the past. From the manual:

PRTG supports Perl Compatible Regular Expressions (PCRE).
PRTG does not support regex options or regex flags like, for example, /g (global), or /s (single line), or /gs, and will not correctly search for the target string if you try to set options.

You'll need to use PowerShell in combination with a EXE/Script (Advanced) Sensor to make use of regex options (within PowerShell) :)


PRTGapi | Feature Requests | WMI Issues | SNMP Issues

Kind regards,
Stephan Linke, Tech Support Team

Created on Mar 25, 2019 7:33:37 AM by  Stephan Linke [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.