Lennart Koopmann

{ :blog => true }

Tag Results

2 posts tagged shell

Introducing the Graylog2 Analytics Shell

I spent my last evenings hacking on a new Graylog2 feature which will be very useful for running powerful analytics on your log messages: The Graylog2 Analytics Shell. The detailled description is in the wiki.

Use this shell to extract information from your log messages. I always like the use case of API monitoring. You could easily find out if that one call is still used by consumers - Or even which consumers are still using it with a simple distinct call:

all.distinct({_oauth_consumer_key}, processed_controller = /^PrivateMessages#.+/)

Watch the shell in action in this short screencast: (Try the full screen mode and HD video)

This is the first working implementation but there is still stuff missing. For example:

  • Shell history available with up and down arrow keys
  • Improved design and layout
  • A history of count and distinct results
  • Tab completion (ZOMG!!)
  • Saving and sharing of commands
  • Short names for streams, to avoid typing the raw stream ID

The shell will be included in the next version: 0.9.6

Post your comments here or discuss in the mailing list.

Release build script for Graylog2

I wrote a shell script that lets me easily create new Graylog2 releases. It bundles Rails with all required gems, configures the release, works on some files and creates a nice .tar.gz package I can test and upload as release.

lennart@sundaysister:~/workspace/graylog2-web-interface/build$ time sudo ./build_release.sh 0.8.2
BUILDING graylog2-web-interface-0.8.2
Copying files ...
Configuring release ...
Freezing Rails and gems ...
Building Tarball ...
DONE! Created Graylog2 release graylog2-web-interface-0.8.2 on Thu Jul 29 21:05:17 CEST 2010

real    0m7.105s
user    0m5.800s
sys 0m1.200s

The script source is available in the graylog2-web-interface GitHub repository: http://github.com/lennartkoopmann/graylog2-web-interface/blob/master/build/build_release.sh