henriwahl / nagstamon Goto Github PK
View Code? Open in Web Editor NEWNagios status monitor for your desktop.
Home Page: https://nagstamon.de
License: Other
Nagios status monitor for your desktop.
Home Page: https://nagstamon.de
License: Other
Hey there,
Just started using Nagstamon today, thanks for a great tool!
I wondered if there was a way to adjust the volume of the notification sound?
Thanks for your help.
I had a look at how Nagstamon was storing the password if the save password option is enabled. I noted that the password is stored in an obfuscated form in the config file which is better than plain-text. However, anyone with a moderate understanding of programming would be able to retrieve the password from a config file given that the software is open source.
I modified the source code of my local installed copy to use the Python keyring module. This was a very quick nasty hack (~4 lines of code) but has the password being stored securely on my system keyring implementation which stores the password in encrypted form on the disk using the login password as the key.
It would be useful if this could be properly integrated into the main code base. Keyring implementations exist for Windows, Linux and MacOS. This would obviously need to manage the python dependency and probably fall-back to obfuscated storage if a system keyring implementation is not available. If a keyring implementation is not available then it would probably be beneficial to warn the user so they can choose whether to proceed or not.
When handling servers with multiple service/host groups it's useful to define a custom url for checking. This already work if a custom URL is specified in Monitor CGI URL like in the following example:
http://icinga.local.domain/icinga/cgi-bin/status.cgi?hostgroup=myhostgroup&style=detail&servicestatustypes=28&serviceprops=10&hostprops=10
However, when doing this it breaks Acknowledgements/Downtime (ie nothing happens if you try to acknowledge or set downtime for the affected service/host).
Hi There,
our checkcommand for hosts is check_ping. If this checkcommand returns a german Umlaut in the status, Nagstatmon only shows an error. In the debug-trace it shows following lines:
DEBUG: 2013-08-02 13:53:09.644000 Default Checking server... DEBUG: 2013-08-02 13:53:14.384000 Default FetchURL: http:///nagios/cgi-bin/status.cgi?hostgroup=all&style=hostdetail&hoststatustypes=12&hostprops=262144&limit=0 CGI Data: None ERROR: 2013-08-02 13:53:14.704000 Default Traceback (most recent call last): File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.Server.Generic", line 1055, in FetchURL File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.BeautifulSoup", line 1519, in __init__ File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.BeautifulSoup", line 1144, in __init__ File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.BeautifulSoup", line 1186, in _feed File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\sgmllib", line 104, in feed ValueError: unichr() arg not in range(0x10000) (narrow Python build) DEBUG: 2013-08-02 13:53:14.704000 Default server return values: ERROR ValueError: unichr() arg not in range(0x10000) (narrow Python build)
The status result of the checkcommand is (copied from Nagios webinterface):
check_ping: Ungültige(r) Hostname/Adresse - xxxxx
We are using nagios Version 3.5.0 and Nagstatmon Version 0.9.10.
Regards
Benjamin
It would be nice to be able to change the view that nagstamon uses when polling check_mk. This way you can create views with different filters to only show the information you want.
Currently you can change the nagstamon view and add a single set of settings. You can also add a regexp filter on the nagstamon side. If you could change the view multiple servers pointing to the same server could be setup with smaller sets of data. Then the dropdown in the list can be used to show what you need to see.
This cannot be done with your regexp filters as those apply to all servers. The check_mk views allow a higher degree of control.
Hi,
Using 0.9.11 (most recent Windows version available), actions no longer seem to work. This has worked before with an older version, not sure which one.
I've set connection method to IP, "address" in the Nagios configuration is set to an IP address (it also has address6 pointing to an IPv6 address, but that's not relevant now I guess, as it breaks for hosts with IPv4 only as well).
When I use the "browser", instead of "command", I can see it uses host_name instead of address. Perhaps this is because I use SSH or PING on a service, and a service doesn't have an address variable (the host has).
Thanks!
Wouter
Hi,
it would be really handy to have two sort option that allows one to set a default sorting method.
The first one could be either Host, Service, Status, Duration, ... and the second one ascending or descending.
Hi,
Is it possible to implement PKCS#11 client certificate authentication in Icinga? We're using this to authenticate a client.
cgi.cfg has the option for this:
use_ssl_authentication=1
From Nagios 3.4.4 the status.cgi has the default limit of 100 row.
For fix the problem the request must have the optins &limit=0
Hello,
Recently using Nagstamon 0.9.11 to monitor Opsview on Ubuntu 12.04
And I have very annoying problem, most notifications doesn't fully appear and there is no horizontal scrolling to see the rest of it.
Screenshot attached (this shot from side to side of screen)
Any fix to this will be very appreciated because it's make the application not usable.
Thank you.
When filtering out 'Acknowledged hosts & services', they disappear completely both from the status bar / tray icon indicator and the Nagstamon window.
I would love to have the option to just filter them out of the status bar / tray icon, but still show up in the list. (Just in case I acknowledge problems and then promptly forget about them.)
I think the left mouse button behavior on the icon is incorrectly mapped as the right button behavior. Instead of getting a colored list of all states with left, I get the same menu with 'Nagstamon >' and Show Details, etc as I do with right.
the size is strange and the position is most of the time wrong.
I have a notebook and an external monitor, with different resolutions, and the popup windows is also partially hidden most of the times - depending on the position of the floating nagstamon.
hello,
I am trying to use Nagstamon (latest version : 0.9.9) for Windows with Check_MK Multisite 1.2.2p1 (and Apache2 on Debian).
I have configured it (http://mathias-kettner.de/checkmk_multisite_nagstamon.html) correctly with full URL to Multisite and login.
But i have this error :
Status: ERROR File "string", line 1
debug log :
DEBUG: 2013-06-06 15:08:14.581000 Recheck all: Rechecking all services on all hosts on all servers...
DEBUG: 2013-06-06 15:08:14.581000 MySite Recheck all: All servers, hosts and services are rechecked.
DEBUG: 2013-06-06 15:08:18.628000 MySite Checking server...
DEBUG: 2013-06-06 15:08:19.581000 MySite Checking server...
DEBUG: 2013-06-06 15:08:27.440000 MySite FetchURL: http://toto.fr/check_mk/view.py?view_name=nagstamon_hosts&output_format=python&is_host_acknowledged=-1&is_service_acknowledged=-1&is_host_notifications_enabled=-1&is_service_notifications_enabled=-1&is_host_active_checks_enabled=-1&is_service_active_checks_enabled=-1&host_scheduled_downtime_depth=-1&is_in_downtime=-1 CGI Data: None
ERROR: 2013-06-06 15:08:27.440000 MySite Traceback (most recent call last):
File "C:\Users\Henri Wahl\Desktop\nagstamon\build\pyi.win32\nagstamon\outPYZ1.pyz/Nagstamon.Server.Multisite", line 206, in _get_status
File "C:\Users\Henri Wahl\Desktop\nagstamon\build\pyi.win32\nagstamon\outPYZ1.pyz/Nagstamon.Server.Multisite", line 181, in _get_url
File "", line 1
<script language="javascript">
^
SyntaxError: invalid syntax
DEBUG: 2013-06-06 15:08:27.440000 MySite server return values: ERROR File "string", line 1
DEBUG: 2013-06-06 15:08:33.444000 MySite ACTION: Browser http://toto.fr/check_mk/
DEBUG: 2013-06-06 15:08:46.885000 Saving config to C:\Documents and Settings\me.nagstamon\nagstamon.conf
when i clic on buttons on Nagstamon, it redirect me on corrects URL of Multisite, for example :
http://toto.fr/check_mk//index.py?start_url=view.py?view_name=nagstamon_svc "Service problems for NagStaMon", this page show services with CRIT status
logs on Apache server are OK for the fetched URL :
X.X.X.X- "" [06/Jun/2013:15:21:00 +0200] "GET /check_mk/view.py?view_name=nagstamon_hosts&output_format=python&is_host_acknowledged=-1&is_service_acknowledged=-1&is_host_notifications_enabled=-1&is_service_notifications_enabled=-1&is_host_active_checks_enabled=-1&is_service_active_checks_enabled=-1&host_scheduled_downtime_depth=-1&is_in_downtime=-1 HTTP/1.1" 200 2282 "-" "Python-urllib/2.7"
when i try this URL (from apache access log : /check_mk/view.py?view_name=nagstamon_hosts&output_format=python&...) in my browser, i see correct data in JSON format :
[ ['host', 'host_icons', 'host_check_age', ..., [u'10.100.208.43',u'','8 sec','3 hrs','1/1','UP',u'OK - 10.100.208.43: ...
I think, the probem comes from Nagstamon and not from Check_MK.
Can you solve this probleme, please ?
best regards
Hugo
hi,
I'm using xubuntu 13.04 and since I updated from 0.9.9 to 0.9.10 the Display Option Statusbar in systray is gone. Do I need to install a additional Python/GTK Package to get it back?
Best regards,
Gabbajoe
Wnen using Multisite sites are not being displayed. I've witten a patch as a workaround. Sitename is now being displayed in the "Status Information" column. It wolud be nice to have a seperate column as the first one.
Patch: https://wiki.mhcsoftware.de/nagstamon
Updated for 0.9.10.
it would be nice if nagstamon would support client certificates as an alternative or in addition to username/password to authenticate agains a monitoring server.
Hi,
This option doesn't work.
I see service of hosts in downtime.
Thank a lot
diff --git a/Nagstamon/Nagstamon/Server/Ninja.py b/Nagstamon/Nagstamon/Server/Ninja.py
index dd53cbe..4cee123 100644
--- a/Nagstamon/Nagstamon/Server/Ninja.py
+++ b/Nagstamon/Nagstamon/Server/Ninja.py
@@ -13,7 +13,7 @@ import cookielib
from Nagstamon import Actions
from Nagstamon.Objects import *
from Nagstamon.Server.Generic import GenericServer, not_empty
-from Nagstamon.BeautifulSoup import BeautifulSoup
+from BeautifulSoup import BeautifulSoup
class NinjaServer(GenericServer):
"""
This is for the current Git version.
Hello Henri,
normally one would escape an carriage return or line feed charater in URLs with %0d (ascii(13)) or %0a (ascii(10)) respectively.
Unfortunately that doesn't seem to work on browser type custom actions - at least on Windows with the current version 0.9.10.
The following example action does create a new email - to and subject fields are also correct, but the mail body is just the literal string "Bitte ein Ticket erstellen und bearbeiten.%0d%0aGruß Dominik"
Is this a bug or do I have to excape a new line differently? Sorry for asking stupid questions, but Google was not a friend of mine on this one yet...
Thanks
Dom
[action_Email to servicedesk]
filter_target_service = True
leave_popwin_open = False
name = Email an Helpdesk
re_status_information_enabled = False
os =
description = Sendet eine Email an den Helpdesk
enabled = True
filter_target_host = True
re_status_information_pattern =
version = 1
re_host_reverse = False
re_status_information_reverse = False
re_service_reverse = False
re_service_enabled = False
re_host_pattern =
re_host_enabled = False
re_service_pattern =
type = browser
close_popwin = True
string = mailto:[email protected]&subject=Nagios Meldung:
I'm working on a multi-monitor desktop, and if I leave the window open, after just a few moments, the Nagstamon window moves to where my mouse is focused.
Hey,
I've read abot Thruk support on the Thruk mailing list. Nice feature for us, cause we're using Thruk as central display frontend for our 12 Nagios servers around the globe.
The problem is that querying the Thruk instance takes quite long and Nagstamon times out. With debugging enabled, I've seen the URL that is querried. This one works fine but needs 35 seconds to load. I bet that the timeout interval is set lower than that.
I havent found a timeout setting in Nagstamon config. Is it possible to set timeouts per Nagios/Icinga/whatever instance?
Or can I increase the overall timeout threshold to test the Thruk implementation?
Thanks for your grat tool!
I'm running Nagstamon 0.9.11 on Ubuntu 13.04. I am monitoring an Icinga server running v1.7.1.
I have checked the Filter box for "Services in soft state" yet I still receive sounds alerts for services that have soft errors. I expected Nagstamon to trigger alerts only when the service went into a hard error state. I can tell that the service never went into a hard state because the contact was not notified by Icinga.
Also, Nagstamon continues to sound alerts after the service returned to an OK state. Is this by design? I would have expected the alert to stop if the service returned to a non-error state. If it's flapping or anything else then Icinga should deal with that.
Thanks in advance for your help.
Hi,
It would be nice to implement an
greets
flam
When running for long periods (weeks), nagstamon progressively uses more and more RAM. At the last check on my (work) desktop VM it was using over 365MB of memory (windows process listing). It monitors only two nagios hosts, each with about 600-1000 checks each. Closing and reopening makes it reset to about 17.4 MB of memory usage. The linux version DOES NOT exhibit this problem.
It seems to leak memory with each GUI operation. i.e. if I right click and select "recheck ALL" memory usage will increase, but never decrease. The more I do it the more ram it eats. It'll initially eat more then free up some, but never equitably (leaking something).
Would it be possible to add the option to run a custom command for each notification level ?
Thanks
Hello,
Any thoughts on implementing handling for SQL and elasticsearch queries?
See: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl.html
Thanks,
Matt
Since Ubuntu 13.04 it's no longer possible to whitelist the application that don't have a Unity icon, so Nagstamon in tray icon mode doesn't work in Ubuntu 13.04.
Hi,
Icinga limits the result by default to max. 50. That results into some not-shown warnings/errors. Appending "&limit=0" or even "&limit=0&start=1" solves that for me.
I am not sure if the "start=1" makes sense in this case and I am also not sure when the limitation has been added to Icinga. I guess it's save to just add it regardless of the version.
I don't think this is a nagstamon bug... but I'm not sure whether it could be worked here anyway.
http://nagios.sourceforge.net/docs/3_0/cgiauth.html explains:
Authenticated contacts* are granted the following permissions for each host for which they are contacts (but not for hosts for which they are not contacts)...
...
Authorization to view status information for all services on the host
My helpdesk users set nagstamon to "hide services on a down host" etc. so that they only see the worst problem. For this reason, they are set up as contacts for the hosts as well as individual services on those hosts.
Some services, like apt/yum updates aren't interesting to them. In Nagios I've set them to not be contacts for these services. They don't receive mail for them, but because of the quote above they do see them in the cgi's. Why doesn't Nagios just let the default host->service contact inheritance work out... I don't know. Nevermind.
So that's why I don't think this is Nagstamon's fault.
But it also seems "by design" for Nagios.
Is there any way to hide services you are not a contact for, or a way I can change my configuration to provide the same functionality?
Since we updated our centreon to 2.4.4 all the checks come back as OK. I have tried with the 9.11 and the problem is still there.
Full-screen mode at this time does not fill the rest of the screen, leaving a huge gutter on the right side of the screen where information could be displayed. Status Information often gets cut-off when there is ample screen space available to show the rest of the message.
I'd love if nagstamon would highlight the latest notification (e.g. when you click the blinking icon in the taskbar, there's something like a "NEW" icon next to the noftification(s) that caused the new alert. I our bigger environment there's always something yellow/red, sometimes it's hard to find the last notification which was added.
Hello
Recently upgraded to 0.9.11 from 0.9.8 adn this has caused an issue. After a certain perdio of use, something (not sure what) causes the Nagstamon window (Set to Short, Statusbar Floating) to no longer stay uppermost and all other Windows appear on top of it. There is no way to fix this except restarting Nagstamon, behavior then return to normal.
This was an issue a couple of years ago, you fixed it with R270 (according to our email conversation) and it was fine in 0.9.8.
OS is Windows XP, I'll try and spot if it's any specific app that causes this if that'll help.
If you have two different server types you still see the "wrong" type when you are over the other type, and that will result in a probably faulty url to that server.
example: one click ack service on ninja
add a ninja host
add a nagios host
click a problem host/service on your nagios server and you see and can choose ninja action.
Please add "Hosts in soft state" as a filter, like there already exists "Services in soft state".
Is there a workaround? Currently one single missed ping over our ADSL line catches my attention as if my server rack is burning ;)
Thank you
The sorting options presented in 0.9.12-devel do not work currently. I am not quite sure how to provide testing/proof of this, is there an option or something I should run to get the info you need?
I'd like it for Nagstamon to utilize libnotify so I get a popup when an alarm triggers, rather than the flashing taskbar icon. Is this possible to implement?
It would be quite useful to have not just one set of default settings for default actions but a customizable list of predefinded settings.
Background:
We're using nagios for our datacenter monitoring. Different alert sources need to be processed by different peoples. To ease the process of alert assignment it would be useful to choose a predefined set of acknoledgement settings from a drop down box. As a result one could acknowledge an alert with a predefined comment of "assinged to xyz" while at the same time "acknowledge all services on host".
The selected set of settings still should be editable so one can modify the comment field or ack-flags if needed.
Other use cases may be possible with "downtime" and "submit check result".
My NagStaMon statusbar in systray displays a white-ish border though the GNOME 2 panel has a dark grey theme.
Is it possible to make the background match the theme? Otherwise, the NagStaMon statusbar gets more visual emphasis than needed.
Fist at all this is a Feature-Request or a Question.
It would be great if the Nagstamon could also support the Icinga Web REST API. Is this a “no go” or did nobody ever thought about this?
The idea behind this, is to get rid of the most http request to the core and the CGI's and move them to another server with a DB Backend (icinga web).
So I tried to do a short dry run with a host check on the REST API of Icinga web. (Output below) I found all attributes witch are also used in the icinga.py except of the duration. But the duration could be calculated in Nagstamon.
Now the Question :)
Is it possible to extend Nagstamon with the REST API icinga web support?
I would also do some preparation work if required.
Kind regards and thanks for your attention.
Jorg
<result><column name="HOST_OUTPUT">PING OK - Packet loss = 0%, RTA = 0.04 ms</column><column name="SERVICE_ID">502</column><column name="HOST_NAME">localhost</column><column name="HOST_DISPLAY_NAME">localhost</column><column name="HOST_CURRENT_STATE">0</column><column name="HOST_LAST_CHECK">2013-07-28 21:32:56</column><column name="HOST_LAST_STATE_CHANGE">2013-05-23 18:16:31</column><column name="HOST_CURRENT_CHECK_ATTEMPT">1</column><column name="HOST_MAX_CHECK_ATTEMPTS">10</column><column name="HOST_STATE_TYPE">1</column><column name="HOST_IS_FLAPPING">0</column><column name="HOST_SCHEDULED_DOWNTIME_DEPTH">0</column><column name="HOST_PROBLEM_HAS_BEEN_ACKNOWLEDGED">0</column><column name="HOST_IS_PENDING">0</column></result>
When launching Nagstamon, for the first couple of seconds, an error message is shown: 'ERROR - IndexError: list index out of range.
(Nagstamon 0.9.11 RC1 on Windows 7, calling two instances of Icinga, this one running 1.0.1, the other 1.7.1)
After a couple of seonds, the real status is shown (This instance, running 1.0.1, reports multiple WARNINGS.)
Note that our second Icinga (version 1.7.1) instance has all status on OK and doesn't show up in the list.
From the debug log:
ERROR: 2013-08-29 10:06:31.021000 Webdog Traceback (most recent call last):
File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.Server.Icinga", line 97, in _get_status
File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.Server.Icinga", line 77, in get_server_version
IndexError: list index out of range
I've used the instructions provided on the nagstamon site to create a ping action. However I noticed that this does not work when the host contains a space. However the Nagios webpage opens correctly if I copy the url from the logfile and replace the space with %20
Nagstamon 0.9.11
Nagios Version 3.2.3
Debug logfile:
DEBUG: 2014-03-31 14:17:29.726000 Nagios IPK FetchURL: http://nagios/nagios/cgi-bin/extinfo.cgi?type=1&host=Mybox Loi CGI Data: None
ERROR: 2014-03-31 14:17:30.153000 Nagios IPK Traceback (most recent call last):
File "c:\Nagstamon\build\build\pyi.win32\nagstamon\out00-PYZ.pyz\Nagstamon.Server.Generic", line 1122, in GetHost
IndexError: list index out of range
DEBUG: 2014-03-31 14:17:30.153000 Nagios IPK Mybox Loi ACTION: COMMAND start ping -t ERROR
Would it be possible to add an option to mute sounds for soft alerts? (Or even add a whole page of filter options for the sound alerts, separate to the current filter page)
I know I can filter soft alerts but that means I don't ever see services that are potentially flapping. I want to be able to notice an impending problem if I'm at my desk BUT I do not want to cause myself (and other people) to come running to answer the sound alert for a soft alert.
Many thanks.
As of 13.04 application whitelisting for the notification area will no longer be supported. Adding support for Unitiy's application indicators will help maintain userbase and provide an opportunity for a much needed facelift of the tray icons.
Unity Application Indicators
Actually, the only solution to support shinken is to install check_mk multisite above shinken ( elements communicate throught the livestatus socket ). And then, configure nagstamon to check the multisite. Better way is nagstamon speak directly on the livestatus tcp socket.
It would be great if there was a little note about building a debian package from source. It seems to be unhappy when I try... i.e.
root@nexus:/usr/src/Nagstamon/build/installer# debuild
This package has a Debian revision number but there does not seem to be
an appropriate original tar file or .orig directory in the parent directory;
(expected one of nagstamon_0.9.9.1.orig.tar.gz, nagstamon_0.9.9.1.orig.tar.bz2,
nagstamon_0.9.9.1.orig.tar.lzma, nagstamon_0.9.9.1.orig.tar.xz or installer.orig)
continue anyway? (y/n) n
Using build.py also didn't work
root@nexus:/usr/src/Nagstamon/build# python build.py
Missing required "rules" file in "/usr/src/Nagstamon/Nagstamon/installer/debian" directory
I run a set-up that uses a database ID as the host name instead of the actual host name, later versions of Nagstamon seems to ignore the display_name configured in Icinga and now shows the host name regardless, which makes it useless to us. The ability to revert to the old behaviour on a server by server basis would correct this.
Hi,
Here, we need to use Nagstamon for more than 6 Nagioses + some iCinga, and we need different filters for each one. Could you make the next version have a feature to make separate filters for each monitoring sites?
Regards,
tumpech.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.