1 / 37

NSClient++ in the new millenium!

NSClient++ in the new millenium!. Name : Michael Medin (@ mickem ) Email: michael@medin.name Blog : http :// blog.medin.name Project: NSClient ++ Web: http :// nsclient.org. ( re )Discovering NSClient++. •. ∘. No disclaimer this year…. Still your fault though!. Michael Medin. d ev.

lilli
Download Presentation

NSClient++ in the new millenium!

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. NSClient++ in the new millenium! Name: Michael Medin (@mickem) Email: michael@medin.name Blog: http://blog.medin.name Project: NSClient++ Web: http://nsclient.org (re)Discovering NSClient++ • ∘

  2. No disclaimer this year… Still your fault though!

  3. Michael Medin dev not ops a long time ago worked in ops by misstake work with “soa” not, C/C++, nagios, icinga, …

  4. No agenda this year either…

  5. About NSClient++ (the program) C++ <0.4.0 linuxand windows Since 2003? not open core Open source Open source modular (pluggable) 0.4.0: 2012-05-xx 0.4.1: 2012-10-xx 0.4.2: 2013-02-xx?

  6. About NSClient++ (the project) one-man-band , no commercial version no company , nopayed time Please don’t be angry! but… sponsoring! = feedback donations! support?

  7. NSClient++ (What can I do?) Fork me on github Update the wiki! Respond in the forums… Submit patches Submit bug reports Come with ideas Tell me what you need! • ∘

  8. NSClient++ (What’s new) Sockets: ipv6, ssl (true) Protocols: NRPE, NSCA, NRDP, check_mk, check_nt, Graphite, syslog, smtp Real-time checks (eventlog, logfiles) Command line syntax • ∘

  9. Thank you!

  10. More then a 1000 words? • ∘

  11. …time for a new logo? but it runs on linux …for windows… Probably! • ∘ By ~Nac-Mac-Feegle

  12. Building on Linux apt-get install … git clone git://github.com/mickem/nscp.git mkdir build ; cd build cmake ../nscp make • ∘

  13. Building on windows… Get visual studio (express), python and cmake Download unpack nscp source python nscp\build\python\fetchdeps.py --target x64 --cmake-configdist cmake ../nscp msbuild /p:Configuration=RelWithDebInfoNSCP.sln • ∘

  14. More then a 1000 words? • ∘

  15. let me work …daemon let nagios/icinga/* rest passive monitoring? NO! event based monitoring? real-time monitoring? The right way to do monitoring? simplified monitoring? preventive monitoring? Tobias Leeger • ∘

  16. More then a 1000 words? • ∘

  17. Secure monitoring no encryption! Check_nt: no authentication, encryption? Check_nrpe: no (strong) authentication! Check_nsca: no authentication, no encryption! Check_mk: No ecryption (in nsclient++) Check_nrdp: Encryption! Authentication! Check_nscp: • ∘

  18. Secure monitoring Check_nt: Encryption! Authentication! Check_nrpe: Encryption! Authentication! Check_nsca: Encryption! Authentication! Check_mk: Encryption! Authentication! Check_nrdp: No ecryption (Yet!) Encryption! Authentication! Check_nscp: • ∘

  19. Security Strong encryption Ssl (standard) Certificates Certificate based authentication Client AND(or) server Secure? I hope so… • ∘

  20. Secure? I hope so… But you never know… • ∘

  21. Time to get real… DEMO: Using NSClient++ • ∘

  22. General usage nscpDisplay all(?) available context nscp --helpGet help (can be used in many places) nscp<context or alias> [options] [-- [module options]] General usage syntax

  23. Contexts help Get help client Act as a client. (think check_nrpe) Usually aliases we can use instead. service (un)Install and display windows service settings Work with configuration test Find errors and problems unit Run unit test scripts

  24. Aliases luaRun lua scripts python Run python scripts nrpeThink check_nrpe nscaThink send_nsca sys Nice pdhfront-end (more to come) wmiWMI front end eventlogAdd event log message from command line

  25. Settings (Configuration) nscp settings --help nscp settings --add-missing --generate [--load-all] Will update your configuration with ALL keys nscpsettings --add-missing --activate-module <module> Great way to "enable a new module“ nscp settings --remove-defaults --generate Will remove all default keys/sections nscpsettings --validate Show problems with the settings file

  26. check_nrpe nscpnrpe -- --help The -- is important nscpnrpe -- -H 127.0.0.1 -c foo -a foo bar Execute nrpe query from nsclient++ 0.4.2 will introduce: nrpe_client-H 127.0.0.1 -c foo -a foo bar nsca_client … …_client …

  27. Time to get real… DEMO: real-time log file monitoring • ∘

  28. Modules CheckLogFile Subscribes to filechanges SimpleFileWriter Write notifications to file NSCAClient Submit NSCA messages NSCP NSCAClient NSCA CheckLogFile SimpleFileWriter FILE

  29. Resulting config from DEMO [/modules] CheckLogFile = enabled SimpleFileWriter= enabled [/settings/logfile/real-time/checks/sample] critical = column2 like 'crit' destination = FILE file = ./test.txt filter = column1 like 'hello' warning = column2 like 'warn' [/settings/logfile/real-time] enabled = true

  30. Resulting config from DEMO [/settings/logfile/real-time] enabled = true [/settings/NSCA/client/targets/default] address = 127.0.0.1 encryption = xor password = secret [/modules] CheckLogFile = enabled NSCAClient = enabled SimpleFileWriter = enabled [/settings/logfile/real-time/checks/sample] critical = column2 like 'crit' destination = FILE,NSCA file = ./test.txt filter = column1 like 'hello' warning = column2 like 'warn'

  31. Run the following ./nscp test tail –f ./output.txt echo –e “hello\tworld” echo –e “hello\twarn” echo –e “hello\tcrit”

  32. Time to get real… DEMO: real-time log file monitoring… …via NRPE? • ∘

  33. Modules CheckLogFile Subscribes to filechanges SimpleCache Store our result NRPEClient Accept remote checks (if there is time) NRPEServer NSCP CheckLogFile CACHE SimpleCache

  34. Resulting config from DEMO [/settings/logfile/real-time] enabled = true [/settings/NSCA/client/targets/default] address = 127.0.0.1 encryption = xor password = secret [/modules] CheckLogFile = enabled NSCAClient = enabled SimpleFileWriter = enabled SimleCache = enabled [/settings/logfile/real-time/checks/sample] critical = column2 like 'crit' destination = FILE,NSCA,CACHE file = ./test.txt filter = column1 like 'hello' warning = column2 like 'warn'

  35. Run the following ./nscp test echo –e “hello\tworld” echo –e “hello\twarn” echo –e “hello\tcrit” In nsclient console execute: check_cache index=sample

  36. Q&A Photo by Olga Berrios

  37. Thank You! Michael Medin michael@medin.name http://www..com/in/mickem http://blog.medin.name/ Information about NSClient++ http://nsclient.org facebook.com/nsclient Slides, and examples http://nsclient.org/nscp/conferances/osmc/2012/

More Related