Python web based interface for log viewing/searching (tail/head/grep)

jph98 jph98 Last update: Jul 08, 2022

Logan Log Viewer

Logan Screenshot

Logan is a web based interface real-time log viewer/searcher.

Built upon:

Installation

Install dependencies with:

sudo pip install flask pyyaml tailer grin

Then run:

./logagent.py

Configuration

Look at logagentconfig.yaml:

Specifies the number of lines to display maximum:

grepnumlines: 250

Specifies the number of lines before/after the match to display:

searchbeforecontext: 2searchaftercontext: 2

Specifies the valid extensions for files found in 'directories':

extensions: - log - out

To configure the directories to view/search within:

directories: - /var/log - /Users/jonathan/temp
Tags:

PRAGMA foreign_keys = off; BEGIN TRANSACTION; COMMIT TRANSACTION; PRAGMA foreign_keys = on;

Subscribe to our newsletter