Dear All,
May be this will help you.
(See attached file: Net_Backup_Total_Report.sh)
With Warm Regards
=-=-=-=-=-=-=-=-=-=-=-=-=-
Harpreet Singh Chana
Phone : (O) 6895 - 4326
Fax : (O) 6895 - 4991
=-=-=-=-=-=-=-=-=-=-=-=-=-
Please do not print this email unless it is absolutely necessary.
Notice
The information in this message is confidential and may be legally
privileged. It is intended solely for the addressee. Access to this
message by anyone else is unauthorized. If you are not the intended
recipient, any disclosure, copying or distribution of the message, or
any action taken by you in reliance on it, is prohibited and may be
unlawful. If you have received this message in error, please delete it
and contact the sender immediately. Thank you.
Dean
<dean.deano@gmail
.com> To
Sent by: VERITAS-BU AT mailman.eng.auburn DOT edu
veritas-bu-bounce cc
s AT mailman.eng DOT aub
urn.edu Subject
Re: [Veritas-bu] command to figure
out size of all backups in a
07/16/2010 06:16 given period
AM
I don't have access to a system right now, so this is just of the top of
my head, but to get the total GB backed up in the last day, I use :
bpimagelist -hoursago 24 |grep IMAGE|awk '{total+=$19}END{print
total/1024/1024}'
... or something like that. To look at the last week, just change the
"hoursago" parameter from 24 to 168
(the $19 might actually be $18 - I can't remember right now)
But yes, what Ed says about expired backups not being included is right.
But as long as you have at least 1 week's retention on all your backups,
the above command works for me.
-
Dean
On Fri, Jul 16, 2010 at 2:24 AM, <judy_hinchcliffe AT administaff DOT com>
wrote:
I have a unix script that emails me the Total.
z=0
for x in $(/usr/openv/netbackup/bin/admincmd/bpimagelist -U -hoursago 64
| grep -v "^[KB-]" | awk '{ print $5 }')
do
z=$(( $x + z ))
done
echo $z | /usr/bin/mail -s "Production Weekend Backups"
someonewhocares AT domain DOT com
set z to 0 so we start out at 0
What the for loop does.
Run the bpimagelist command (this will run for each server you have
configured) and get info back to 64 hours - I do 64 because I only run
this for the weekend backups. You would want two - one to run for 24
hours to get your daily backup totals. And one to run for your weekend
(or just do one each day))
It then greps for all lines except for the header (has a KB in it) or the
separator line which has a - in it)
Then we awk out column 5 which is the kb's backed up for each server.
That amount is the x variable
Add that x to z which started out as 0
And do it again, adding to z until you get the total for all you backed
up in the last number of hours.
Then it emails that total.
Which for me gets put into a chart once a week so I can watch how much we
grow.
-----Original Message-----
From: veritas-bu-bounces AT mailman.eng.auburn DOT edu [mailto:
veritas-bu-bounces AT mailman.eng.auburn DOT edu] On Behalf Of Heathe Yeakley
Sent: Thursday, July 15, 2010 10:59 AM
To: VERITAS-BU AT mailman.eng.auburn DOT edu
Subject: Re: [Veritas-bu] command to figure out size of all backups in a
given period
How much data was backed up in the last week
- /usr/openv/netbackup/bin/admincmd/bpimagelist -U -hoursago 336
How much data was backed up on April 26th
- /usr/openv/netbackup/bin/admincmd/bpimagelist -U -d 04/26/02
00:00:00 -e 04/27/02 00:00:00
How much data was backed up on client XYZ in the last week
- /usr/openv/netbackup/bin/admincmd/bpimagelist -U -client XYC -hoursago
168
- /usr/openv/netbackup/bin/admincmd/bpcatlist -client xxx
On Thu, Jul 15, 2010 at 1:25 AM, ddobek
<netbackup-forum AT backupcentral DOT com> wrote:
>
> I am using NBU 6.0 on a unix mst/media server, and i need to find out
the size of all backups in a given week. I need to request disk size to
have backups written to, as we change from using tape to disk for
storage.
> i can use either the gui or command line, CLI is my preference is there
is a command to find this info.
> thanks for the help.
>
> +----------------------------------------------------------------------
> |This was sent by devon_dobek AT mentor DOT com via Backup Central.
> |Forward SPAM to abuse AT backupcentral DOT com.
> +----------------------------------------------------------------------
>
>
> _______________________________________________
> Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
> http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
>
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
ForwardSourceID:NT0016363A
Net_Backup_Total_Report.sh
Description: Binary data
_______________________________________________
Veritas-bu maillist - Veritas-bu AT mailman.eng.auburn DOT edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
|