Code Monkey home page Code Monkey logo

apache_log_parser's Introduction

Description

It's a bash script to parse an apache access log file.

Analysizing Apache log files to count most visited Unique Ip , to see http status codes , request method and most viewed unique URLS manually is an not an easy task due to the size of log file and less readability of log file.

Every time a web page is requested, an email sent or a login made, the event is recorded in a log file. An essential skill for any system administrator is to be to able parse through log files and extract useful information.

This script can be used for this purpose:


Feature

The script will extract data from log file such as :

  • IDENTIFY FROM WHICH IPS MY SERVER HAS BEEN ACCESSED MORE AND HOW MANY TIMES (TOP 20 IP ADDRESSES )
  • View request types GET/HEAD/POST/DELETE that are happening the most
  • View highest 20 requested unique base URLs.
  • View the most common response codes your visitors are causing.

How to use this script

- To get sample access log for practice purpose use:
  
  wget http://www.almhuette-raith.at/apache-log/access.log

- git clone https://github.com/NITHIN-JOHN-GEORGE/apache_log_parser.git

- cd apache_log_parser

- In prod environment where real access log is available , update the access log file path in script starting

Log_File=<apache access log file absolute path>

- ./apache_log_analyser.sh

Script Running

CAPTURE-1 CAPTURE-2 CAPTURE-3 CAPTURE-4 CAPTURE 5

apache_log_parser's People

Contributors

dev1git avatar nithin-john-george avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.