OR statement In Search Field

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
stefanchap
Posts: 4
Joined: Fri Oct 17, 2014 3:44 am

OR statement In Search Field

Post by stefanchap »

Hi,

Is there any way to search for more than one server names graphs all connected with an OR statement?

Example:

I have two servers, namely server1.*cpu and server 2.*cpu
(The .*cpu means that i am getting just the cpu graph of the given server)

My search term would look something like "Server1" OR "Server2" and the result of my search would be the two graphs appearing as the result.

Any ideas?

Thanks.
stefanchap
Posts: 4
Joined: Fri Oct 17, 2014 3:44 am

Re: OR statement In Search Field

Post by stefanchap »

Another hint, hopefully helps to brainstorm.

Is there any way to play with the URL?

https://......../graph_view.php?action=preview&host_id=0&filter=server1.*cpu

This one generates one graph successfully. i have tried playing around and add the second one but it doesnt work
stefanchap
Posts: 4
Joined: Fri Oct 17, 2014 3:44 am

Re: OR statement In Search Field (Solved)

Post by stefanchap »

Use the following syntax and you should get an or statement search query

(server1|server2|server3)

So this symbol ---> | stands for the OR statement in cacti

You can go even further and get specific elemens of servers such as cpu using the following:

(server1.*cpu|server2.*cpu|server3.*cpu)

Hope this helps someone out there! :)
mstbone67a
Posts: 28
Joined: Mon Sep 21, 2009 9:31 am

Re: OR statement In Search Field

Post by mstbone67a »

Which version is this supported in?

We were able to search with%
like this:
0.8.7g
xsr%250 would show all the xsr devices with graphs with 250 in the name.

just installed a new box with
0.8.8c
and the search for xsr%250 causes the window to return
xsr%0 and no graphs display.

What wildcards/regex is supported in the graph search? in Graph Viewing (Tree, List, Preview)
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests