Alex,
For number of file spaces that haven't backed up:
select count(*) from filespaces where backup_end<current_timestamp-1 day
For total number of filespaces:
select count(*) from filespaces
For names of filespaces:
select node_name, filespace_name from filespaces where
backup_end<current_timestamp-1 day
I hope this helps.
Alex Paschal
Storage Administrator
Freightliner, LLC
(503) 745-6850 phone/vmail
-----Original Message-----
From: Alexander Lazarevich [mailto:alazarev AT ITG.UIUC DOT EDU]
Sent: Monday, August 04, 2003 12:23 PM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: select statement?
Hi,
TSM 5.1.6.5 on windows 2K server. I'm trying to make a command script that
will tell me how many filespaces have a BACKUP_END greater than 1 day.
Then I want it to email those results to me. That way if a client stops
backing up I'll get an email about it and go fix it. The emailing can be
handled by another server, but I need to get the correct SQL statement and
I'm not an SQL guy.
Preferably I'd like an email with a subject of '430/455 clients backed up
on 08/04/2003', or something like that. So I need to count the number of
filespaces that have a BACKUP_END greater than 1 day. I think you can just
set a variable with $1=something. But I don't know how to get the current
time from the server.
Someone else must do this and have a quick answer. Otherwise, I'll just
keep trying to figure it out. I can do it in perl, but I'd rather not.
Thanks in advance,
Alex
--- ---
Alex Lazarevich | Systems Administrator | Imaging Technology Group
Beckman Institute - University of Illinois
alazarev AT itg.uiuc DOT edu | (217)244-1565 | www.itg.uiuc.edu
--- ---
|