Certainly.
Here is my statement for querying the accounting log for the previous
workday/night:
LOG_Q=`dsmadmc -id=foo -pa=bar -outfile=actlog.tmp q actlog begindate=TODA
Y-1 begintime=17:00:00 enddate=TODAY endtime=05:59:59`
and later I clal it with:
echo "Unavailable tape list: $TAPELIST " >>$REPORT
So, my guess would be you could set a variable thus so:
CHECKIN_Q=`dsmadmc -id=foo -pa=bar q actl begint=-48` |grep '119 minutes'
(I couldn't get the "search" term to the command line without ADSM freaking
out)
You could also use the -outfile=filename parameter to chunk it to disk to do
darn near any type of text processing you'd like with it.
and provide the answer later with
echo "My info: $CHECKIN_Q" >>$REPORT
Hope that helps
Jerald Sheets, Systems Analyst TIS
Our Lady of the Lake Regional Medical Center
5000 Hennessy Blvd, Baton Rouge, LA 70808
Ph.225.765.8734..Fax.225.765.8784
E-mail: [EMAIL PROTECTED]
-----Original Message-----
From: George Lesho [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 03, 2001 10:03 AM
To: [EMAIL PROTECTED]
Subject: Q ACTL / SEARCH question
%SMers, From the command line interface, using a search string bounded by
quotation marks will allow you to input a search string with spaces:
example:
tsm: AFCOPS2>q actl begint=-48 search="119 mi nutes"
Date/Time Message
--------------------
----------------------------------------------------------
07/01/01 14:03:07 ANR8765I 055: 3570 volume 074C18 in location
datactr is
required for use in library
3575LIB1; CHECKIN LIBVOLUME
required within 119 mi nutes.
The same command, from the command line produces an error using quotes to
bound the search string.
example:
afcops2: /usr/local/bin # dsmadmc -id=<<<userid>>> -pass=<<<passwd>>>
begint=-48 search="119 mi nutes"
Tivoli Storage Manager
Command Line Administrative Interface - Version 3, Release 7, Level 2.0
(C) Copyright IBM Corporation, 1990, 1999, All Rights Reserved.
Session established with server AFCOPS2: AIX-RS/6000
Server Version 3, Release 7, Level 3.6
Server date/time: 07/03/01 09:45:18 Last access: 07/03/01 09:33:02
ANS8000I Server command: 'begint=-48 search=119 mi nutes'
ANS8001I Return code 3.
ANS8002I Highest return code was 3.
Is there anything that I can do to introduce search strings with spaces into
a command line "q actl". I removed the userid and
password from the command line example below for security purposes.
Thanks -
George Lesho
AFC Enterprises
Storage/System Admin