Wrong filter?

This support forum board is for support questions relating to Nagios Log Server, our solution for managing and monitoring critical log data.
Locked
User avatar
rhassing
Posts: 416
Joined: Sat Oct 05, 2013 10:29 pm
Location: Netherlands

Wrong filter?

Post by rhassing »

Hello,

What could be wrong with the following filter:
I have a logentry:

Code: Select all

VMM01 wms[6466]: <126005> <6466> <WARN> <VMM01 10.10.32.11> |ids| Interfering AP: The system classified an access point (BSSID 00:df:03:00:00:26 and SSID MB WLAN 61619 on CHANNEL 6) as interfering. Additional Info: Detector-AP-Name:AP-03-AP135; Detector-AP-MAC:00:5d:00:48:00:c0; Detector-AP-Radio:2.
And my filter looks like this:

Code: Select all

if [message] =~ /VMM01.*\|ids\|.*/ {
   grok {
        match => [ 'message', 'VMM01.*\|ids\| %{GREEDYDATA:dis-type}: %{GREEDYDATA:data}' ]
   }
   mutate {
        replace => [ 'type', 'aruba-ids' ]
   }
}
If I apply this filter all logging seems to be dropped for this logsource.

Best regards,
Rob Hassing
Image
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Wrong filter?

Post by mcapra »

I think that's incorrect syntax for a replace step:
https://www.elastic.co/guide/en/logstas ... te-replace
Former Nagios employee
https://www.mcapra.com/
User avatar
rhassing
Posts: 416
Joined: Sat Oct 05, 2013 10:29 pm
Location: Netherlands

Re: Wrong filter?

Post by rhassing »

That replacement is working for this filter:

Code: Select all

if [type] == 'syslog' and [message] =~ /.*Insight.*/ {
   grok {
        match => [ 'message', '.*Insight.*Auth.Username=%{USERNAME:user},Auth.Protocol=%{GREEDYDATA:protocol},Auth.NAS-IP-Address=%{IP:nas-ip},CppmNode.CPPM-Node=%{IP:cppm-node},Auth.Login-Status=%{INT:status},Auth.Service=%{GREEDYDATA:service},Auth.Roles=%{GREEDYDATA:role},Auth.Enforcement-Profiles=%{GREEDYDATA:profile}.*' ]
   }
   mutate {
        replace => [ 'type', 'clearpass' ]
   }
}
Rob Hassing
Image
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Wrong filter?

Post by ssax »

I labbed it up with your exact ones and it's working properly on mine.

Please PM me a copy of your profile, you can download it from Admin > System Status by clicking the Download System Profile button.
User avatar
rhassing
Posts: 416
Joined: Sat Oct 05, 2013 10:29 pm
Location: Netherlands

Re: Wrong filter?

Post by rhassing »

Very strange, I re applied the same filter and now it's working. :D
Not sure what went wrong the other day...
Rob Hassing
Image
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Wrong filter?

Post by benjaminsmith »

Hi Rob,

Glad to hear it's working now.

We'll go ahead and close this post, but feel free to open another if you have any new questions.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked