About Jeroen
Contact
FAQ
Status
Todo in my life
His Blog
Articles
Photo Gallery

Outdoor:
  Recumbing
  Running

Software:
  jnitodo
  squidefender
  Wormwarner

Latest books read:
  • Lincoln Child - Deep Storm
  • Lee Child - The Hard Way
  • Mike Lawson - Dead on Arrival
  • Preston & Child - Still Life with Crows

Latest movies seen:
  • Death Race
  • The Objective
  • Deception
  • Hellboy - The Golden Army



23 September 2008

yellowbullet 20:55: Today it is 5 years ago that I registered the jeroen.se domain.
more

25 August 2008

yellowbullet 17:46: Since a few weeks I use the jnitodo todo list manager for managing my todo list. jnitodo was written by myself, so it matches my requirements quite well and it might match yours!
more

13 August 2008

yellowbullet 12:51: Yesterday I ran into a bug in my Samsung S1060 digital camera. If you press the view photos button while the red-eye flash pictogram is flashing white and red it hangs and becomes unresponsive.
more

11 August 2008

yellowbullet 12:59: While migrating my account to another machine which uses openldap authentication I ran into the problem that cron were not working on the new machine. A quick look in the logs revealed the following error:
more

29 July 2008

yellowbullet 17:50: I often get the question how I manage to survive my long commute time during the week. This question is often raised when in a conversation it becomes clear that I travel over 4 hours per day by train. In this blog post I will try to give a small insight in how I manage this.
more

09 July 2008

yellowbullet 13:23: Just a quick blog post about how to run a command like uptime in more than one screen window. Just do crtl-a then
:at "#" stuff "uptime\015"
more

28 June 2008

yellowbullet 21:58: I just reached the 1000 kilometer mark with my recumbent bike. It took me 46 hours and 24 minutes, averaging a 21.55 km/h speed. The last month however my average cycling speed is increasing, so I should do the next 1000 kilometer in less time.
more

Introduction

Because I am someone who has the tendency to put too much appointments on his calendar, I decided to search for a solution to avoid this. So I needed someone or something to give me a warning before I do that. Being a system administrator I decided to use nagios to give me that warning and wrote a nagios plugin that parses ICS calendar files.

The plugin

The plugin which can be downloaded here has the following options:
-a - The number of days to lookahead.
-h - The hours you have in a day (I use 14.5.).
-w - Percentage. If your allocated time is above this percentage a warning will be generated.
-c - Percentage. If your allocated time is above this percentage a critical will be generated.
-f - The location of your ICS file.

How I use the plugin

I have two checks defined. One which looks 7 days ahead and one which looks 28 days ahead. Both checks use the 14.5 hours in a day threshold. I sleep for 8 hours or so and need time to eat. So this sounded to me as a reasonable value. Anyway, these are my checks:
nagios_busy.pl -f datebook.ics -a 7 -w 80 -c 85
nagios_busy.pl -f datebook.ics -a 28 -w 75 -c 80

Bugs

Currently does not work with repeating events.

Picture of me


Everything I say on these pages are opinions, they are not necessarily the truth.
Commercial use of the data on this site without permission is strictly prohibited.
Unique number: fc38fc2c1347a9824cef263d20748ced
7:05AM up 40 days, 21:34, 5 users, load averages: 0.21, 0.16, 0.06
XML

Powered by FreeBSD Generated by a bunch of M4 macros on Wed Oct 1 03:09:03 CEST 2008
$Id: monitoring_calendar_with_nagios.m4 2194 2008-06-27 20:09:03Z jnieuwen $
© 2002 - 2008 Ir. Jeroen van Nieuwenhuizen
I know I'm not perfect but I can smile.