Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search/Host not in Regex doesn't work #273

Closed
anthonyhaussman opened this issue Jan 29, 2014 · 14 comments
Closed

Search/Host not in Regex doesn't work #273

anthonyhaussman opened this issue Jan 29, 2014 · 14 comments

Comments

@anthonyhaussman
Copy link

Hi,

In Thruk Version 1.80~3, i have an issue to display a filter with a not in regex.
For example, i don't want to display host in the regex ' ^mp3lg4-out.* '.

When i add the filter :
Search !~ ^mp3lg4-out.*
or
Host !~ ^mp3lg4-out.*

It still displays these hosts.

But when i try the filter in regex :
Search ~ ^mp3lg4-out.*
or
Host ~ ^mp3lg4-out.*

It works well and only display good hosts.

@sni
Copy link
Owner

sni commented Jan 29, 2014

Could you try it on http://demo.thruk.org, i cannot reproduce it, so i assume its fixed already.

@anthonyhaussman
Copy link
Author

It seems to be ok on the demo.
I will install the last nightly build for debian 6 (1.81~2014-01-29_debian6_amd64) and watch if it corrects my problem.

@anthonyhaussman
Copy link
Author

I's really strange.
I have installed the version of thruk 1.81~20140129.

But unfortunately it doesn't work on my side but work well on the demo.
The only file where i didn't make the update configuration is /etc/thruk/cgi.cfg.

Here the url of the filter i test on the demo :
http://demo.thruk.org/thruk/#cgi-bin/status.cgi?style=combined&nav=&hidesearch=2&hidetop=1&title=All%20Unhandled%20Problems&hst_s0_hoststatustypes=4&hst_s0_servicestatustypes=31&hst_s0_hostprops=10&hst_s0_serviceprops=0&referer=status.cgi%3Fnewname%3D%26svc_s0_servicestatustypes%3D28%26svc_s0_val_pre%3D%26section%3DBookmarks%26service_columns%3D1%26service_columns%3D2%26service_columns%3D3%26service_columns%3D4%26service_columns%3D5%26service_columns%3D6%26service_columns%3D7%26service_columns%3D8%26service_columns%3D9%26service_columns%3D10%26service_columns%3D11%26service_columns%3D12%26service_columns%3D13%26service_columns%3D14%26service_columns%3D15%26service_columns%3D16%26service_columns%3D17%26service_columns%3D18%26service_columns%3D19%26hst_s0_hostprops%3D10%26svc_s0_value_sel%3D5%26hst_s0_servicestatustypes%3D31%26hidesearch%3D2%26svc_s0_op%3D!~%26nav%3D%26svc_s0_serviceprops%3D10%26svc_s0_hoststatustypes%3D3%26all_col%3D%26all_col%3D%26hst_s0_hoststatustypes%3D4%26style%3Dcombined%26svc_s0_hostprops%3D10%26hidetop%3D1%26hst_s0_serviceprops%3D0%26svc_s0_value%3D%255Enaemon*%26title%3DAll%2BUnhandled%2BProblems%26host_columns%3D1%26host_columns%3D2%26host_columns%3D3%26host_columns%3D4%26host_columns%3D5%26host_columns%3D6%26host_columns%3D7%26host_columns%3D8%26host_columns%3D9%26host_columns%3D10%26host_columns%3D11%26host_columns%3D12%26view_mode%3Dhtml%26svc_s0_type%3Dsearch&bookmark=%2Fthruk%2Fcgi-bin%2Fstatus.cgi%3Fstyle%3Dcombined%26nav%3D%26hidesearch%3D2%26hidetop%3D1%26title%3DAll%2BUnhandled%2BProblems%26hst_s0_hoststatustypes%3D4%26hst_s0_servicestatustypes%3D31%26hst_s0_hostprops%3D10%26hst_s0_serviceprops%3D0%26section%3DBookmarks%26newname%3D%26view_mode%3Dhtml%26host_columns%3D1%26host_columns%3D2%26host_columns%3D3%26host_columns%3D4%26host_columns%3D5%26host_columns%3D6%26host_columns%3D7%26host_columns%3D8%26host_columns%3D9%26host_columns%3D10%26host_columns%3D11%26host_columns%3D12%26service_columns%3D1%26service_columns%3D2%26service_columns%3D3%26service_columns%3D4%26service_columns%3D5%26service_columns%3D6%26service_columns%3D7%26service_columns%3D8%26service_columns%3D9%26service_columns%3D10%26service_columns%3D11%26service_columns%3D12%26service_columns%3D13%26service_columns%3D14%26service_columns%3D15%26service_columns%3D16%26service_columns%3D17%26service_columns%3D18%26service_columns%3D19%26all_col%3D%26all_col%3D%26svc_s0_hoststatustypes%3D3%26svc_s0_servicestatustypes%3D28%26svc_s0_hostprops%3D10%26svc_s0_serviceprops%3D10%26update.x%3D12%26update.y%3D7%26svc_s0_type%3Dsearch%26svc_s0_val_pre%3D%26svc_s0_op%3D!~%26svc_s0_value%3D%255Enaemon*%26svc_s0_value_sel%3D5&section=Bookmarks&newname=&view_mode=html&host_columns=1&host_columns=2&host_columns=3&host_columns=4&host_columns=5&host_columns=6&host_columns=7&host_columns=8&host_columns=9&host_columns=10&host_columns=11&host_columns=12&service_columns=1&service_columns=2&service_columns=3&service_columns=4&service_columns=5&service_columns=6&service_columns=7&service_columns=8&service_columns=9&service_columns=10&service_columns=11&service_columns=12&service_columns=13&service_columns=14&service_columns=15&service_columns=16&service_columns=17&service_columns=18&service_columns=19&all_col=&all_col=&svc_s0_hoststatustypes=3&svc_s0_servicestatustypes=28&svc_s0_hostprops=10&svc_s0_serviceprops=10&update.x=13&update.y=9&svc_s0_type=search&svc_s0_val_pre=&svc_s0_op=!~&svc_s0_value=%5Enaemon.*&svc_s0_value_sel=5

On my side :
http://shinken.stcon.wan/thruk/#cgi-bin/status.cgi?style=combined&nav=&hidesearch=2&hidetop=1&title=All%20Unhandled%20Problems&hst_s0_hoststatustypes=4&hst_s0_servicestatustypes=31&hst_s0_hostprops=10&hst_s0_serviceprops=0&referer=status.cgi%3Fnewname%3D%26svc_s0_servicestatustypes%3D28%26svc_s0_val_pre%3D%26section%3DBookmarks%26service_columns%3D1%26service_columns%3D2%26service_columns%3D3%26service_columns%3D4%26service_columns%3D5%26service_columns%3D6%26service_columns%3D7%26service_columns%3D8%26service_columns%3D9%26service_columns%3D10%26service_columns%3D11%26service_columns%3D12%26service_columns%3D13%26service_columns%3D14%26service_columns%3D15%26service_columns%3D16%26service_columns%3D17%26service_columns%3D18%26service_columns%3D19%26hst_s0_hostprops%3D10%26svc_s0_value_sel%3D5%26hst_s0_servicestatustypes%3D31%26hidesearch%3D2%26svc_s0_op%3D~%26nav%3D%26svc_s0_serviceprops%3D10%26svc_s0_hoststatustypes%3D3%26all_col%3D%26all_col%3D%26hst_s0_hoststatustypes%3D4%26style%3Dcombined%26svc_s0_hostprops%3D10%26hidetop%3D1%26hst_s0_serviceprops%3D0%26svc_s0_value%3D%255Emp3lg4-out.*%26title%3DAll%2BUnhandled%2BProblems%26host_columns%3D1%26host_columns%3D2%26host_columns%3D3%26host_columns%3D4%26host_columns%3D5%26host_columns%3D6%26host_columns%3D7%26host_columns%3D8%26host_columns%3D9%26host_columns%3D10%26host_columns%3D11%26host_columns%3D12%26view_mode%3Dhtml%26svc_s0_type%3Dsearch&bookmark=%2Fthruk%2Fcgi-bin%2Fstatus.cgi%3Fstyle%3Dcombined%26nav%3D%26hidesearch%3D2%26hidetop%3D1%26title%3DAll%2BUnhandled%2BProblems%26hst_s0_hoststatustypes%3D4%26hst_s0_servicestatustypes%3D31%26hst_s0_hostprops%3D10%26hst_s0_serviceprops%3D0%26section%3DBookmarks%26newname%3D%26view_mode%3Dhtml%26host_columns%3D1%26host_columns%3D2%26host_columns%3D3%26host_columns%3D4%26host_columns%3D5%26host_columns%3D6%26host_columns%3D7%26host_columns%3D8%26host_columns%3D9%26host_columns%3D10%26host_columns%3D11%26host_columns%3D12%26service_columns%3D1%26service_columns%3D2%26service_columns%3D3%26service_columns%3D4%26service_columns%3D5%26service_columns%3D6%26service_columns%3D7%26service_columns%3D8%26service_columns%3D9%26service_columns%3D10%26service_columns%3D11%26service_columns%3D12%26service_columns%3D13%26service_columns%3D14%26service_columns%3D15%26service_columns%3D16%26service_columns%3D17%26service_columns%3D18%26service_columns%3D19%26all_col%3D%26all_col%3D%26svc_s0_hoststatustypes%3D3%26svc_s0_servicestatustypes%3D28%26svc_s0_hostprops%3D10%26svc_s0_serviceprops%3D10%26update.x%3D14%26update.y%3D5%26svc_s0_type%3Dsearch%26svc_s0_val_pre%3D%26svc_s0_op%3D~%26svc_s0_value%3D%255Emp3lg4-out.*%26svc_s0_value_sel%3D5&section=Bookmarks&newname=&view_mode=html&host_columns=1&host_columns=2&host_columns=3&host_columns=4&host_columns=5&host_columns=6&host_columns=7&host_columns=8&host_columns=9&host_columns=10&host_columns=11&host_columns=12&service_columns=1&service_columns=2&service_columns=3&service_columns=4&service_columns=5&service_columns=6&service_columns=7&service_columns=8&service_columns=9&service_columns=10&service_columns=11&service_columns=12&service_columns=13&service_columns=14&service_columns=15&service_columns=16&service_columns=17&service_columns=18&service_columns=19&all_col=&all_col=&svc_s0_hoststatustypes=3&svc_s0_servicestatustypes=28&svc_s0_hostprops=10&svc_s0_serviceprops=10&update.x=6&update.y=9&svc_s0_type=search&svc_s0_val_pre=&svc_s0_op=!~&svc_s0_value=%5Emp3lg4-out.*&svc_s0_value_sel=5

So seems to be ok. But :
selection_021

Quite confusing. :/

@sni
Copy link
Owner

sni commented Jan 29, 2014

Assuming you are using shinken (your url looks like that) i tried the demo with only selecting the shinken backend and then i can reproduce it. So it seems to be a shinken problem.

@Seb-Solon
Copy link
Contributor

@sni damned you got us 😢

@sni
Copy link
Owner

sni commented Jan 29, 2014

unfortunatly i cannot redirect issues to you ;-) (or i don't know how)

@Seb-Solon
Copy link
Contributor

Well, I think it's Livestatus related so he will have to open the ticket here : https://github.com/shinken-monitoring/mod-livestatus

Can you tell me the query done to get the list? So that we can confirm the bug by querying the LS with telnet :)

@anthonyhaussman
Copy link
Author

Effectively i use Shinken for backend.
Sorry that i didn't specify before. I have test it with only the shinken backend on the demo and i reproduce the problem.

Ok sni. Thanks for your help. :)
I will check if i can have help from Shinken.

@anthonyhaussman
Copy link
Author

@Seb-Solon
I will open a ticket right now.
But about the excact query made by Thruk to Shinken. I don't know how to have this information.

I have only the url with the cgi option.

@Seb-Solon
Copy link
Contributor

I was asking @sni actually not to make you find it :)

You can launch LS in debug mode to see the query executed but it's a bit difficult (output is messy and the "good" line is hard to find). That could save you a lot of time and help us to reproduce it by a simple "echo blabla | nc localhost 50000"

BTW if sni has the answer we can close and move to the other repo ;)

@sni
Copy link
Owner

sni commented Jan 29, 2014

i can give you an example query later

@anthonyhaussman
Copy link
Author

Perfect. :)
I have already open a ticket about the subject on the repo issue : shinken-monitoring/mod-livestatus#14

Thanks for your help @Seb-Solon

@sni
Copy link
Owner

sni commented Jan 29, 2014

pasted you a sample query, so i will close the issue here.

@sni sni closed this as completed Jan 29, 2014
@Seb-Solon
Copy link
Contributor

Thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants