ADSM-L

Re: Delete running schedule

2002-10-10 16:17:22
Subject: Re: Delete running schedule
From: Bill Boyer <bill.boyer AT VERIZON DOT NET>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Thu, 10 Oct 2002 16:15:56 -0400
The example I supplied does not delete the schedule, nor does it leave
temporary schedules around. It just updates itself to run again if the
condition is met. If not, then it runs and updates itself to start at the
normal time. No temporary schedules....no deleting youself.....

So to change your script to fit in my example...

select * from processes
if (RC_OK) goto Reschedule
if (RC_NOTFOUND)goto Runnow
exit
/**/
Reschedule:
/*  Something is running. Schedule myself to start in an hour */
upd sched r_reclaim_on_$1 t=a startt=+01:00
exit
/**/
Runnow:
/*  Nothing is running. Reset myself to the original time for next week   */
/*  and reset the reclamation threshold for the storage pool.             */
upd sched r_reclaim_on_$1 t=a startt=<your start time>
upd stg $1 reclaim=$2
exit

-----Original Message-----
From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU]On Behalf Of
Rupp Thomas (Illwerke)
Sent: Thursday, October 10, 2002 11:04 AM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: AW: Delete running schedule


Thanks for your response.

I want to do Recalamation every Saturday. Therefore I defined a Schedule tos
 tart the Script ILL_START_RECLAIM. If this Script detects running processes
it defines a new (temporary) Schedule to run itself again in 1 hour.
If after 1 hour all processes have finished Reclamation is started and the
temporary Schedule should be deleted.
This deletion raises the error message.
Why I want to delete the Schedule? Because I want no temporary Schedules
lurking
around for a week or longer.

Thomas Rupp
Vorarlberger Illwerke AG
Mail:   thomas.rupp AT illwerke DOT at
Tel:    +43/5574/601-2583





-----Urspr|ngliche Nachricht-----
Von: Bill Boyer [mailto:bill.boyer AT VERIZON DOT NET]
Gesendet: Donnerstag, 10. Oktober 2002 16:31
An: ADSM-L AT VM.MARIST DOT EDU
Betreff: Re: Delete running schedule


Why delete yourself? Just UPDATE youself. Here's a script a co-worker put
together to make sure that no backupset processes are running before
starting the expire inventory task:

select process_num from processes where process like '%BACKUPSET%'
if (RC_OK) goto Reschedule
if (RC_NOTFOUND)goto Expirenow
exit
/**/
Reschedule:
upd sched expire_inventory t=a startt=+00:20
exit
/**/
Expirenow:
upd sched expire_inventory t=a startt=15:00 startd=+1
expire inventory duration=510
exit


Bill Boyer
DSS, Inc.


-----Original Message-----
From: ADSM: Dist Stor Manager [mailto:ADSM-L AT VM.MARIST DOT EDU]On Behalf Of
Rupp Thomas (Illwerke)
Sent: Thursday, October 10, 2002 9:58 AM
To: ADSM-L AT VM.MARIST DOT EDU
Subject: Delete running schedule


Hi *SM-ers,

the following script starts Reclamation when there a no processes running.
If there is a process active it is rescheduled after 60 minutes.

         select * from processes
         if (rc_ok) goto reschedule
         UPDATE STGPOOL $1 RECLAIM=$2
         DELETE SCHEDULE R_RECLAIM_ON_$1 TYPE=A    <==
         exit
         reschedule:
         del sch r_reclaim_on_$1 type=a
         def sch r_reclaim_on_$1 t=a cmd="run -
             Ill_Start_Reclaim $1 $2" -
             active=yes startt=NOW+0:60 peru=o

Line 4 (marked with <==) returns error

ANR2706E CSCMDSCH(1157) Scheduler database query failed: 2.

because it tries to delete a running schedule (itself).
Is there a supported way to delete a running schedule?

Kind regards and greetings from Austria
Thomas Rupp
Vorarlberger Illwerke AG
Mail:   thomas.rupp AT illwerke DOT at
Tel:    +43/5574/601-2583





----------------------------------------------------------------------------
--------------
Dieses eMail wurde auf Viren geprueft.

Vorarlberger Illwerke AG
----------------------------------------------------------------------------
--------------


----------------------------------------------------------------------------
--------------
Dieses eMail wurde auf Viren geprueft.

Vorarlberger Illwerke AG
----------------------------------------------------------------------------
--------------

<Prev in Thread] Current Thread [Next in Thread>