Regular Expressions 101

Community Patterns

Regex para Logs de Kiwi Log Forwarder

0

Regular Expression
Python

r"
(?P<FechayHora>(?:20[0-9]{2}-[0-1]\d-[0-2]\d)\s(?:(?:[0-1]\d|2[0-3]):){2}(?:[0-1]\d|2[0-3]))(?:,|\s)(?P<LogLevel>(?:\w*\.?\w*))(?:,|\s)(?P<Hostname>(?:\d{1,3}\.){3}\d{1,3}|(?:\w*\.cerrey\.com\.mx))(?:,|\s)(?P<mensaje>\"?[\w\s:,\[\]()/-]*\"?)
"
gm

Description

Loading markdown...
Submitted by anonymous - 8 months ago