25
The Nagios light-bar David Stern [email protected]

Nagios Conference 2013 - David Stern - The Nagios Light Bar

  • Upload
    nagios

  • View
    30.399

  • Download
    2

Embed Size (px)

DESCRIPTION

David Stern's presentation on The Nagios Light Bar. The presentation was given during the Nagios World Conference North America held Sept 20-Oct 2nd, 2013 in Saint Paul, MN. For more information on the conference (including photos and videos), visit: http://go.nagios.com/nwcna

Citation preview

Page 1: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The Nagios light-bar

David [email protected]

Page 2: Nagios Conference 2013 - David Stern - The Nagios Light Bar

What is it?

Page 3: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Why do we need it?

DoD work requires air-gapped networks

How would you know if a service is down if you’re not on the network?

Page 4: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The Hardware

Page 5: Nagios Conference 2013 - David Stern - The Nagios Light Bar

An unobstructed View

Page 6: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Backside of base unit: connection to light-bar

Page 7: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Equipment network discovery program

Initial connection requires crossover cable

Page 8: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Base unit generates a webpage

Page 9: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The Settings tab allows you to configure the device

Page 10: Nagios Conference 2013 - David Stern - The Nagios Light Bar

You need to identify the type of device

Page 11: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Security settings

Page 12: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Optional settings

Page 13: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The network MUST be active before you power-on the unit

It might be a smart idea to set the light-bar for DHCP address

It would be a smart idea to monitor that the light-bar is available

Page 14: Nagios Conference 2013 - David Stern - The Nagios Light Bar

If I can control the light-bar from the web, why not use WGET

Page 15: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The Secret Sauce; undocumented

http://light-bar/cmd.cgi\?action=ST\&t=A2\&a=1 makes the light-bar go beep

http://light-bar/cmd.cgi\?action=ST\&t=A2\&a=0 turns off the noise

http://light-bar/cmd.cgi\?action=ST\&t=GR\&a=1 makes the green light go on

http://light-bar/cmd.cgi\?action=ST\&t=GR\&a=0 turns off the green light

Substitute OR for GR to affect the orange(yellow) light

Substitute RE for GR to affect the red light

Page 16: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Getting nagios status

We can get the nagios status from the Service page:

http://nagios-server/nagios/cgi-bin/status\?host=all

Just search it for “serviceTotalsPROBLEMS”

N.B. You may need to insert authentication information in URL

http://nagiosadmin:nag-password@nagios-server/nagios/cgi-bin/status\?host=all

You can use the same format for the light-bar authentication

Page 17: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Mission Creep

How about if we get the light-bar to beep the first time a new alert occurs?

And since we don’t use nagios WARNING conditions, let’s use the yellow light to indicate unacknowledged alerts

Let’s put it all together…

Page 18: Nagios Conference 2013 - David Stern - The Nagios Light Bar

This is NOT a plugin

Page 19: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Other cool things you can do with WGET

Hierarchical Nagios:A core nagios aware of other installs

Page 20: Nagios Conference 2013 - David Stern - The Nagios Light Bar

What’s different on this nagios page?

Page 21: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Configuring “hierarchical” nagios

• Backup nagios before and after these changes• Install a Nagios server in each lab/sub-site• Edit side.{html,php}, Add stanza for each sub-

site and set refresh=300,• Tag each nagios sub-site: Main.{html,php} and

status.c status.cgi• Modify light-bar cron job to check each sub-

site, swap red,green dots as needed

Page 22: Nagios Conference 2013 - David Stern - The Nagios Light Bar

One way to present the pages

Page 23: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Another way to present the data

Page 24: Nagios Conference 2013 - David Stern - The Nagios Light Bar

The Results

Faster response time/higher uptime

Better awareness of our networks

Page 25: Nagios Conference 2013 - David Stern - The Nagios Light Bar

Questions?