Python-based log monitoring system that parses Linux authentication logs (/var/log/auth.log) to detect failed and successful login attempts, and stores structured data in PostgreSQL for analysis. Designed for automation with cron jobs, modular Python scripts, and database integration.
- Parse authentication logs and extract timestamp, username, IP, and event type.
- Insert structured log data into PostgreSQL.
- Automate log monitoring using Linux cron jobs.
- Modular and reusable Python scripts.
- Python 3 (Pandas, psycopg2)
- PostgreSQL
- Linux / Ubuntu
- Cron
- Clone repo:
git clone https://github.com/yourusername/linux-log-monitor.git - Install dependencies:
pip install pandas psycopg2-binary - Configure PostgreSQL and update
log_parser.pyconnection settings. - Run script:
sudo python3 log_parser.py - Optional: automate via cron.
Feel free to contribute, suggest improvements, or help debug issues! Your contributions are welcome :D :D