Coder Social home page Coder Social logo

apachdatacollect's Introduction

apachdatacollect

Monitor apache usage during production and or testing

This monitors the following:

  • system file usage
  • apache open file count
  • apache parent process rss
  • apache child threads average size rss
  • apache thread count
  • apache load relative to request/sec and throughput per request

Prerequsities

  • mod_status enabled

Script called apache_data_collect_high_load.sh

Arguments: 1 takese timeout count in seonds

Can be operationized via cron

e.g.

#start script 6 am it will run for 17 hrs or 61200 seconds you can adjust this as desired crontab -e

0 6 * * * /bin/bash /root/apache_data_collect_high_load.sh 61200 > /dev/null 2>&1

Output directory is hard coded to /var/tmp/apachedatarh

The script will overwrite daily to mitigate against creating filesystem space issues.

If you have mail in enabled the script has a commented out example of how to email the data out.

Output looks as follows:

#datetime@@file_usage@@apache_lsof_file_count@@parent_apache_process_rss@@avg_child_rss_kb@@apache_ps_thread_count@@apache_load
20191108_102001@@@@770@@11960@@6427@@215@@<dt>.000308 requests/sec - 1 B/second - 5.4 kB/request</dt>
20191108_102031@@@@770@@11960@@6427@@215@@<dt>.000331 requests/sec - 1 B/second - 5.5 kB/request</dt>

If you want to test outside of cron first you can run, recommend that you do this first

/bin/bash /root/apache_data_collect_high_load.sh 60 

apachdatacollect's People

Contributors

dsullivarh avatar

Watchers

 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.