We have some cisco devices , all of them have the same syslog configuration.
The normal format should like:
<187>11640: PH18L1_CS29SW01: Oct 19 09:11:45.797 GMT: %LINK-3-UPDOWN: Interface GigabitEthernet1/0/13, changed state to down
then i can using some pattern to grok that,
but now i can receive some unusual syslog
it just like as below:
<187>11640: PH18L1_CS29SW01: ]: Oct 19 09:11:45.797 GMT: %LINK-3-UPDOWN: Interface GigabitEthernet1/0/13, changed state to down
I don't know why,because all the switches have the same configuration.And until now i can not find any valid pattern to grok the error syslog message, i had tried to use self-defined pattern, but still doesn't work.
My question is how can i match the unexpected string " ]",and please notice that there is a space before ].Thanks
Actually i have tried to use "^\s{1}]$" to match the string , it does work when i using it individually .But the problem is that if i using the grok expression such as %{HOSTNAME}:%{UNP:hahha} (I defined " unp ^\s{1}]$" in my pattern),it doesn't work !!!
Wow it does work,but i find something interesting , i tried to replace it by ”(^\s+]$)?“
It does work , but i can not find the string that i've defined , such as
Wow it does work,but i find something interesting , i tried to replace it by ”(^\s+]$)?“
It does work , but i can not find the string that i've defined , such as
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.