Experimenting with Amon: lightweight server and application monitoring
You know what I love more than puppies and Thanksgiving stuffing? Really great tools that are both awesome, and easy to use. Amon falls into that "awesome and easy" category.
Amon is a great monitoring solution for single-server applications that allows you to see, in just a few minutes, the critical statistics on your server, and its resources. This works because, while some may be all abuzz about scaling, the truth is that most applications out there (and certainly most test/dev apps) basically run on one or two servers - an app server, and a database server. If you're an independent developer, or someone working on a side/hobby project, then why would you go through all the work of setting up a complicated monitoring structure when you could just add Amon in literally 10 minutes?
I'm experimenting with Amon on an AWS Ubuntu instance, which basically runs a small JVM-based network utility. I didn't configure exception logging for my experiment.
Setting up Amon is basically three steps:
- Run curl install.amon.cx | bash
- Edit /etc/amon.conf with your specific settings
- Run sudo /etc/init.d/amon start
The Amon config file on my test system is a simple set of JSON settings, shown below:
{
"acl": "False",
"system_check_period": 60,
"secret_key": "[omitted]",
"process_checks": [
"java",
"mongo",
"amon",
"amond"
],
"web_app": {
"host": "keyspace.karmanebula.com",
"port": "80"
},
"backend": {
"mongo": {
"host": "127.0.0.1",
"port": [omitted]
}
}
}