Created
July 31, 2020 03:31
-
-
Save hieunt79/7d62a4fd25c3dde2263a14329ab9fc02 to your computer and use it in GitHub Desktop.
Count rp10m, rph of log file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
LOG_FILE=$1 | |
#for hour in 00 01 02 03 | |
#do | |
# pattern=" $hour" | |
# rph=`egrep " $hour:" $LOG_FILE | wc -l` | |
# echo $hour : $rph | |
#done | |
for hour in 00 01 | |
do | |
for min in 0 1 2 3 4 5 | |
do | |
rp10m=`egrep " $hour:$min" $LOG_FILE | wc -l` | |
echo $hour:$min : $rp10m | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment