GeneralException

Family, work and life in general.

Archive for the ‘ Ruby ’ Category

On GOD and MONIT

Tuesday, August 25th, 2009

When I recently resurrected this blog from after an untimely demise, I found it interesting to see how many people still get here from Google by querying for God.  When I first wrote that article, I had been planning to launch a little app for home brewers that I was writing in my spare time.  I still have the project around and I do plan to launch it at some point, but its not on my short list of things to-do with my ever dwindling spare time (I have twin babies due in seven weeks).

Since then, I’ve started a new job with Agora Games as CTO, and our (good natured, ninja, rockstar) systems administrator Jason LaPorte sold me on Monit.  Why would a guy who gets most of his blog traffic (read: all 10 of you) based on a Google referral for GOD use Monit?   I think there’s a few reasons.

  1. Stability – Monit is very very stable.  It follows my favorite Unix design philosophy and does a very limited set of things,very, very well.
  2. Simplicity – Monit configs are really easy to write, even for someone who isn’t a Unix Ninja.  Yes reader, even YOU can set up and configure Monit.  Likely in under a few minutes!
  3. Overlord – Using Monit and a few simple bash scripts Jason pieced together a really simple systems management application in Rails.  Its not for everyone, but it works really well for us.

God is good.  God is great.  But, when you architect web applications for a living, eventually you realize that however great Ruby is (and Ruby as a language is truly awesome), having one less MRI process running, eating up RAM on your servers is really nice.  Its even nicer when your using a virtual hosting solution and you’re paying a premium for memory.  At this point, until we have a better Ruby interpreter my money (and our business) runs on Monit.  YMMV.

God – Ruby Process Monitoring

Thursday, January 3rd, 2008

I’ve been playing a lot lately with God, a process monitoring tool written in Ruby by Tom Preston-Werner. If you run your app on either a VPS (I use Slicehost) or on a dedicated host, a monitoring tool is a must have for several reasons.

First, and most importantly, you can use it to keep an eye on your application. When things go awry (as they always do) you can have god do things like alert administrators, restart processes, and anything else you can write a script to do.

Second, you can also use god as a general process control tool. Often times you have application specific processes you want to run when the server starts up. When you have only one application per server it might make some sense to handle this with shell scripts in init.d. However, many us have multiple apps on the same server. In this environment using init.d for application specific startup scripts means letting application specific tasks leak out of the application folder and mix with the main server configuration. So, rather than creating bash scripts to handle this you can let God do it and keep these scripts where they really belong; with the application.

That said, here’s my setup..

(more…)