Update cache-stats.sh to include the port 80 proxy
Adding cache stats for port 80 requires a little refactoring to account for the lack of a port number in the 80/tcp (default port) proxy logs. This also slightly alters the output for the sake of keeping the script simple. Change-Id: I431a54445ff5bcb7f4a38bd30b73f00e4d7892f7
This commit is contained in:
parent
62a7f45951
commit
a8a59b479d
@ -1,11 +1,12 @@
|
||||
#!/bin/bash
|
||||
for X in 0 1 2 ; do
|
||||
HITS=$(grep ' cache hit ' /var/log/apache2/${HOSTNAME}*_808${X}_access.log | wc -l)
|
||||
REFRESHES=$(grep ' conditional cache hit: entity refreshed ' /var/log/apache2/${HOSTNAME}*_808${X}_access.log | wc -l)
|
||||
MISSES=$(grep ' cache miss: ' /var/log/apache2/${HOSTNAME}*_808${X}_access.log | wc -l)
|
||||
for X in /var/log/apache2/${HOSTNAME}*_access.log ; do
|
||||
HITS=$(grep ' cache hit ' ${X} | wc -l)
|
||||
REFRESHES=$(grep ' conditional cache hit: entity refreshed ' ${X} | wc -l)
|
||||
MISSES=$(grep ' cache miss: ' ${X} | wc -l)
|
||||
|
||||
echo "Port 808${X} Cache Hits: $HITS"
|
||||
echo "Port 808${X} Cache Refresshes: $REFRESHES"
|
||||
echo "Port 808${X} Cache Misses: $MISSES"
|
||||
echo "${X}"
|
||||
echo "Cache Hits: $HITS"
|
||||
echo "Cache Refresshes: $REFRESHES"
|
||||
echo "Cache Misses: $MISSES"
|
||||
echo ""
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user