Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

New FAQ added ...

Status
Not open for further replies.

PGPhantom

IS-IT--Management
Nov 4, 2002
545
CA
To reduce confusion over backup speeds I wrote faq776-3984 to help clarrify what you should be seeing in terms of backup speeds - Let me know if this helps ...
 
Good FAQ. However, it just opened more questions for this novice. How do you figure what speed you are actually getting? The GUI tells you elapsed time but that time includes waiting for a drive(s) to become available. Is there a log that tells the actual time spent writing and reading or are you doing dedicated backup runs to check throughput? I am doing both multiplexing and multistreaming and don't understand how to calculate my speed. Thanks for the help.
 
I do not recall where I got this or who wrote it so I cannot give due credit to a really good script ... Here is what I use:


#!/bin/ksh
#
#########################################################################
#
# Script to report average throughput for the previous nights backups.
#
# Creation Date: July 17th, 2003
# Modification Date: July 17th, 2003
#
#########################################################################

#########################################################################
#
# Set up variables

MASTER=
<your Master server>
BPDIR=
<your Install dir>/netbackup/bin/admincmd
AWKPROG=
<location for results>/awk.prog
STATS=
<location for results>/nb.stats
OUTPUT=
<location for results>/Global_Drive_Thruput.txt
hoursago=72
Change this to the number of hours to query against
ADMCMD=
<your Install dir>/netbackup/bin/admincmd

#########################################################################
#
# Initialize Log Files
#

if [ -s $AWKPROG ]
then
rm $AWKPROG
fi

if [ -s $STATS ]
then
rm $STATS
fi

if [ -s $OUTPUT ]
then
rm $OUTPUT
fi

#########################################################################
#
# Perform actions

thruputformat() {
echo &quot;\n => Backup <=&quot; >>$OUTPUT
cat $STATS | grep -v duplicate | grep -v restore |
awk -F\, '{print $NF}' |
awk -f $AWKPROG >>$OUTPUT

echo &quot;\n => Duplicate <=&quot; >>$OUTPUT
cat $STATS | grep duplicate |
awk -F\, '{print $NF}' |
awk -f $AWKPROG >>$OUTPUT

echo &quot;\n => Restore <=&quot; >>$OUTPUT
cat $STATS | grep restore |
awk -F\, '{print $NF}' |
awk -f $AWKPROG >>$OUTPUT
echo &quot;&quot; >> $OUTPUT
echo &quot;<><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><&quot; >> $OUTPUT
echo &quot;&quot; >> $OUTPUT
}
#
# End Functions
#
# Create an awk program file to be used later
echo '
BEGIN {bytes=0;thruput=0;items=0}

$2==&quot;Kbytes&quot; && $3==&quot;at&quot; {bytes+=$1; thruput+=$4;items++}
$1==&quot;total&quot; && $2==&quot;Kbytes&quot; {bytes+=$3; thruput+=$5;items++}
$2==&quot;total&quot; && $5==&quot;Kbytes&quot; {bytes+=$4; thruput+=$7;items++}

END {
print &quot;Total Volume: &quot; bytes/1024 &quot; Mbytes&quot;;
if (items>0) {print &quot;Average Throughput: &quot; thruput/items &quot; KBytes/sec &quot;int(((thruput/items)*60)/1024) &quot; MBytes/min&quot;}
}
'> $AWKPROG
#
# Here is where the real script BEGINS
#
# First we want to make sure that no jobs are active
# this will provide more accurate thruput results.
#
$ADMCMD/bpdbjobs -M $MASTER -report | grep Active >/dev/null
#
# Set variable NOJOBS to the return code of previous line
# if it returned a zero (0), then the condition of the
# until loop is met. If not, we stay in the until
# loop until it is met, sleeping for 10 minutes each
# time the condition is not met
#
#
#
NOJOBS=$?
until [ $NOJOBS -ne 0 ]
do
sleep 600
$admcmd/bpdbjobs -M $MASTER -report | grep Active >/dev/null
NOJOBS=$?
done
#
# Now the report can be run on the thruput.
#
$ADMCMD/bperror -M $MASTER -hoursago $hoursago|grep Kbytes/sec > $STATS
echo &quot;===============================================================================&quot; >>$OUTPUT
echo &quot;\t`date`\n&quot; >>$OUTPUT
echo &quot;Global Thruput Summary Report of Master Server $MASTER &quot; >> $OUTPUT
echo &quot;Reporting on the previous $hoursago hours&quot; >>$OUTPUT
echo &quot;===============================================================================&quot; >>$OUTPUT
#
# Call Thruput function
thruputformat
#
# Find all Media Servers to report on
#
$ADMCMD/bpstulist -L | grep Host | sort -u| awk '{print $3}' |
while read mediaserver
do
$ADMCMD/bperror -M $MASTER -server $mediaserver -hoursago $hoursago |
grep Kbytes/sec > $STATS
echo &quot;===============================================================================&quot; >>$OUTPUT
echo &quot;\n\t`date`&quot; >>$OUTPUT
echo &quot;Individual Thruput Summary Report of Media Server:$mediaserver&quot; >>$OUTPUT
echo &quot;Reporting on the previous $hoursago hours&quot; >>$OUTPUT
echo &quot;===============================================================================&quot; >>$OUTPUT
#
# Call Thruput function
thruputformat
#
done
#
# Uncomment if you want this to be delivered to someone_who_cares
#cat $OUTPUT | mailx -s &quot;Throughput Statistics Summary&quot; $someone_who_cares
rm -f $AWKPROG $STATS
 
IS this for 3.4 or 4.5...? Maybe both?

Joe Despres
 
It should work on both
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top