-
Notifications
You must be signed in to change notification settings - Fork 25
Documentation
Welcome to Logl! We're glad you made it here. Here's what you need to do to get Logl up and running:
-
Install pip
Pip is a tool for installing Python packages. If you don't already have pip, you can install it here:
http://www.pip-installer.org/en/latest/installing.html# -
Install PyMongo
PyMongo, MongoDB's language driver for Python, is a prerequisite for running Logl. You can download and install PymMngo using pip, as described here:
http://api.mongodb.org/python/current/installation.html -
Install MongoDB (which you should all do anyway because it is awesome)
Help all of us at 10gen out by downloading MongoDB 2.1.2, our latest development release, and helping us test for 2.2!
http://www.mongodb.org/downloads -
Install a non-text-based browser
We recommend Google Chrome or Firefox. -
Install Logl
COMING SOON
In order to run logl, you must also have a mongod running in the background:
$ ./mongod
Logl is runnable from the command line. Once you have a mongod running, navigate to the top-level logl directory and run the following:
$ python logl/logl.py logfile1 logfile2...
Feed Logl your log files as command line arguments. If you don't have any log files to try with Logl, we've provided some samples so you don't have to miss out on the fun:
$ python logl/logl.py test/1.log test/2.log test/3.log test/4.log test/5.log
Once Logl has launched a web page, it will spawn a python server that will run until you shut it down with Ctrl+C. Be sure to kill this server once you are finished with the visualizer. Happy Logling!
We've tried to build Logl with you in mind, but every person wants something a little different from their log visualizer. So, we built Logl to make it customizable! If you're familiar with Python and JavaScript and there's something specific you'd like to track, you can add in your own filters to catch special kinds of log messages.
- Write a python filter
The first round of processing that Logl handles involves a series of filters that parse through the log files. This filters can be found in logl/logl/filters. We've provided an empty filter, template.py, with some structuring to help get you started.
Once a filter finds a log line that fits its requirements, it stores that log as a document in the mongod. The structure of these documents is outlined in each filter, and is slightly different for each type of message. If you're writing your own filter, its documents will have to contain the fields that are outlined in template.py. Feel free to add additional fields, if you'd like.
We'd love to hear your input.