cancel
Showing results for 
Search instead for 
Did you mean: 

Autoreaction - consolidated email reqd once daily

Former Member
0 Kudos

We are using an autoreaction to send emails when a background job fails.

Currently we receive an email for every failed job. We would like to have a single consolidated email daily listing all failed jobs.

Is this possible? If yes, how? Any help will be appreciated.

We are using SAPCCM4X and a solman central autoreaction assigned to the monitored system using RZ21.

Solman EhP1 SP4

Monitored system: ECC6 SP14

Thanks

Prasad

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Prasad,

in my opinion this is no problem of the alerting - autoreaction method - but of the data collector.

Long time ago, I had to alert job aborts for different customers depending on the client. There was no standard SAP data collector. So I wrote one of my own.

I guess that this should be possible with your problem: writing a collector which checks the current day. Then a "collective alert" should be processed, listing all aborted jobs from current day.

Feel free to call back,

Dirk

Former Member
0 Kudos

Thanks Dirk!

Your suggestion looks interesting! Can you send me a link which explains how to write a data collector?

I am assuming this will need ABAP coding and will result in a custom program...

Thanks

Prasad

Former Member
0 Kudos

Hi Prasad,

yes, you are right. You need to write a data supplier on your own. Have a look at this document to see howto:

http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/d6957732-0701-0010-36b5-cae4fcdc4...

Before working through the whole stuff, some hints from me ( I am an admin, no developper; but I managed to write durable data suppliers on my own, so you will manage this too).

Keep in mind, that there are three different MTE types: performance, protocol and status MTEs. With your job monitoring, you need to write a status MTE. CCMS knows two kinds of data suppliers: active (meaning scheduled automatically, eg kernel components) and passive ones (meaning: being scheduled by CCMS background schedulers). You have to create a passive data supplier.

Writing data suppliers alway consists of two elements: 1.) creating the MTEs (nodes) in RZ20 and 2.) collecting the data and reporting the results into this MTE.

For 1.) have a look at the link, for 2.) in your case try something like this (it will be a part of your report):

*Business-Logic: aborted jobs

data: count type i,

jobdate type d,

jobdate2 type d,

mandt type t000-mandt,

jobname like tbtco-jobname,

jobcount like tbtco-jobcount,

reluname like tbtco-reluname,

value type i,

alerttime type t.

data: begin of wa,

authckman like tbtco-authckman,

jobname like tbtco-jobname,

jobcount like tbtco-jobcount,

strtdate like tbtco-strtdate,

endtime like tbtco-endtime,

sdldate like tbtco-sdldate,

reluname like tbtco-reluname,

status like tbtco-status,

end of wa,

itab like sorted table of wa

with unique key authckman jobname jobcount.

jobdate = sy-datum.

jobdate2 = sy-datum - 1.

alerttime = sy-uzeit.

  • concidering periodical schedule of data supllier (here: 600 sec) --> change into 24h

alerttime = alerttime - 600.

select * from tbtco client specified

into corresponding fields of table itab

*where status = 'A'.

where status = 'A' and authckman ne sy-mandt.

*nur Jobs des heutigen Tages anzeigen

delete itab where strtdate le jobdate2.

*nur Jobabbrüche der letzten 10 Minuten melden (Periode Datensammler)

delete itab where endtime le alerttime.

  • Anzahl der abgebrochenen Jobs ermitteln

describe table itab lines value.

  • WIRD EINE GRÜN oder ROT-Meldung erzeugt?

if value eq 0.

  • GRÜN-Meldung, wenn keine abgebrochenen Jobs existieren

MSG_VAL = AL_VAL_GREEN.

MSG_NO = 051.

Hope this will help ypu; you can extend your monitoring by creating a message class and a message for the alerts of your own; there you can pack in your job infos coming out of this data supplier.

Kind regards,

Dirk

Former Member
0 Kudos

Hi,

we monitor and set auto rezction for each job in RZ20. there is a separate mte for each back job included in the table, so the alerts are also dynamic and separate.

sry cant consolidate.

Regards,

Kaustubh.

Former Member
0 Kudos

>

there is a separate mte for each back job included in the table,

Thanks Kaustubh, this is something new to me. Can I know the full path of such MTEs in RZ20?

Also, can I know whether we can trigger alerts only for a particular user's failed jobs?

Thank you

Prasad