Page 1 of 1

How to schedule a set of jobs under single group

Posted: 27 Jun 2007 12:05
by Sunil
Hi,

I need to schedule a set of jobs under a single group name since the next run of the same set of jobs will depend on the successful completion of this previous run.If one job fails, the next run should not happen.

Any ideas are welcome!!!!!! :roll:


Thx
Sunil

Posted: 27 Jun 2007 2:50
by sunform2
I don't known if it's answer to our question, but ...

Do you known the ctmorder option : -AUTOEDIT.

You can use it to change the %%APPLGROUP to rename the group order.

Define jobs in a group named : GRP01

and use ctmorder ........ -AUTOEDIT %%APPLGROUP TEST01

This command create a group name TEST01 in the AFJ with the jobs define in GRP01.

To have real separate group, with there own condition, use the autoedit variable %%APPLGROUP in the name of condition.

Exemple : CND_%%APPLGROUP._001-OK

Posted: 27 Jun 2007 5:01
by mauriziog
Immagine a job that starts only after the "group" of jobs is ended ok (that is the operation normal/default of control-m). If this control job can do the "rerun" action of all the "group", this resolve your problem?

If the answer is yes i have the solution.
:wink:

use scheduling group

Posted: 27 Jun 2007 8:35
by gglau
Put the jobs ina scheduling group. The scheduling group has an in condition. The scheduling group has an out condition of NEXT odate, using the same name as that of in condition.

Active jobs in the scheduling group run only when the in condition exists. If any job fails, the out condition for next order date is not created. Next day's jobs, although ordered, will not run until the condition is created manually.

If not using scheduling group, insert a dummy job above all top-most jobs and another dummy job below all bottom-most jobs of all job streams in the group. Use in condition and out condition in the dummy jobs as described above in scheduling group.

Hope this help!

Posted: 28 Jun 2007 8:35
by Sunil
mauriziog wrote:Immagine a job that starts only after the "group" of jobs is ended ok (that is the operation normal/default of control-m). If this control job can do the "rerun" action of all the "group", this resolve your problem?

If the answer is yes i have the solution.
:wink:
Yes...This is the scenario.
could You Please help out?????

Thx ---> :idea:

Posted: 28 Jun 2007 11:46
by mauriziog
Well Sunil, the situation is:

"Immagine a job that starts only after the "group" of jobs is ended ok (that is the operation normal/default of control-m). If this control job can do the "rerun" action of all the "group".

In this job (run it on the controlm server machine), put the following command:

ctmpsm -UPDATETABLE "TableName" RERUN

In the "TableName" is possible to put wilcard "*", with naming be sure that all the "group" of jobs and only thises are selected for the action.

Posted: 28 Jun 2007 12:37
by Sunil
mauriziog wrote:Well Sunil, the situation is:

"Immagine a job that starts only after the "group" of jobs is ended ok (that is the operation normal/default of control-m). If this control job can do the "rerun" action of all the "group".

In this job (run it on the controlm server machine), put the following command:

ctmpsm -UPDATETABLE "TableName" RERUN

In the "TableName" is possible to put wilcard "*", with naming be sure that all the "group" of jobs and only thises are selected for the action.
Well...Now am going in more detail level.
This "group" of jobs may run once/twice/trhrice on daily basis depends on the incoming feed.
Could you please let me know how to create the "group".I hope this could be done by the following:
ctmcreate \
-tasktype GROUP
----------
----------
Can you please confirm the above ???

Posted: 28 Jun 2007 2:43
by mauriziog
Hi, Sunil
The group of jobs change or is always the same?

If the group is the same, create or order/force the group is not secure:
- if the first group is still running, order a second one can be catastrofic
- if the first has one job notok, ordering a second goup generate a problem: starts immediatly the first job of the chain and still the job that were red in the first flow.

So if the group is the same i have resolved in this manner:
The rerun job is the point of control:
-a if you want to run many times the group for example every hour: the rerun job is ciclic and run every hour.
-b if you want that the group run after some appens: the rerun job is ciclic and rerun immediatly but wait still for an external condition. When the condition is added it starts and reruns the table.

Doing so the jobs of the group runs many times but in the EM are only one with many sysout: monitoring and control is very clear.

This solution is a metod created by me for doing the event schedulation: una table runs one or many times depending of events.

I hope that you like it, is a simple, clear and powerfull solution.

The create or the order-like metod are used only if the jobs are not still in the AJF and all the times the conditions changes.

If you want I can send to you a draft with the two examples a and b.

Posted: 28 Jun 2007 3:06
by Sunil
mauriziog wrote:Hi, Sunil
The group of jobs change or is always the same?

If the group is the same, create or order/force the group is not secure:
- if the first group is still running, order a second one can be catastrofic
- if the first has one job notok, ordering a second goup generate a problem: starts immediatly the first job of the chain and still the job that were red in the first flow.

So if the group is the same i have resolved in this manner:
The rerun job is the point of control:
-a if you want to run many times the group for example every hour: the rerun job is ciclic and run every hour.
-b if you want that the group run after some appens: the rerun job is ciclic and rerun immediatly but wait still for an external condition. When the condition is added it starts and reruns the table.

Doing so the jobs of the group runs many times but in the EM are only one with many sysout: monitoring and control is very clear.

This solution is a metod created by me for doing the event schedulation: una table runs one or many times depending of events.

I hope that you like it, is a simple, clear and powerfull solution.

The create or the order-like metod are used only if the jobs are not still in the AJF and all the times the conditions changes.

If you want I can send to you a draft with the two examples a and b.
Hi,
It would be great if you could send the draft one!!! :lol:

Posted: 28 Jun 2007 3:22
by mauriziog
My e-mail is "maurizio.giraudi@dinamica-si.it", send me one message, so i can send to you a draft.

My Enterprise Manager version is 6.2 or 6.3, 6.1.3 cant read these draft !

Posted: 28 Jun 2007 3:42
by mauriziog
I'VE UPLOAD ONE DRAFT HERE:
Votre URL est http://www.scheduler-usage.com/Uploads/mauriziog

see if you find it.

Another thing:

the first run of the "group" is done with a ctmudly command, so the first time is there. But if the table is in SYSTEM you can only put the time on the first job.

Posted: 03 Jul 2007 5:49
by mauriziog
Sunil,
resolved? all ok?

:P