Git Product home page Git Product logo

mping's Introduction

Screen Shot

mping

Bash script that utilize ping command with visual, audio and statistics aids.

Usage

mping runs as like ping but it has to get an integer as second parameter which express the minimum allowed response time in milliseconds. Any response takes more than that time, mping will highlight it in red color and plays beep command with beep sound.

After exit the command CTRL C a simple statistics with total run time, shortest response time, longest response time and the count of exceeded response will be printed.

./mping.sh 192.168.1.1 20

You also can copy it to /usr/bin to run it globally as a command:

chmod +x mping.sh

sudo cp mping.sh /usr/bin/mping

Notice:

For systems that do not support the beep command such as OpenSuse. You can install the sox package and then use it play a mp3 file with the beep sound from a bash script named beep placed in /usr/bin directory with execution permissions. The following steps may help:

  1. Install sox package sudo zypper install sox
  2. Create a file named beep.sh with the following line play -q beep-sound.mp3 and save the file.
  3. Download any beep mp3 sound file of your choice and rename it to beep-sound.mp3
  4. Make the bash script file executable by chmod +x beep.sh
  5. copy the two files to /usr/bin by sudo cp beep.sh /usr/bin/beep note, we removed the extension from beep.sh and sudo cp beep-sound.mp3 /usr/bin/beep-sound.mp3

Now the beep command inside the script will be emulated using the script we have done above.

About

This script has initiated using Bing Chat and I added some modifications to it.

mping's People

Contributors

saidbakr avatar

Stargazers

Mohammad Hewedy avatar Karthikeyan A K 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.