Automatic email notifications from iSeries

330 pts.
Tags:
AS/400
RPG
Nagi needs to write a code on his iSeries 870 to send a notifications to his e-mail, such as server rebooting, jobs not started or need reply, etc. He's a Windows guy, and doesn't know where to start. Can someone help him with the code and possibly send him steps on how to write it and where and which LIB it will reside, as well as the CL commands? -- Michelle Davidson, editor, Search400.com
ASKED: September 26, 2005  2:14 PM
UPDATED: November 14, 2009  11:33 AM

Answer Wiki

Thanks. We'll let you know when a new response is added.

first, have SMTP configured (if no, seek search400 for help).
how to check ? :
SNDDST TYPE(*LMSG)
TOINTNET((‘myemail@mycompany.com’))
DSTD(DESCRIPTION)
MSG(MESSAGE)
LONGMSG(‘long message’)

second, insert this model everywhere you need.
for example in the startup program when need to check IPL starting (DSPSYSVAL QTRUPPGM give the name)

third, you need to survey your QSYSOPR message queue. I have a model for you at http://jplamontre.free.fr/jpltools.htm + search QSYSOPR

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    No offense, but having a "Windows" person assigned to this is nuts. Trying to grasp why the SNDDST command, for example, can be useful requires knowledge of obsolete functions that shouldn't even be used. The actual SMTP functions are what should be used. Most iSeries programmers can't even say why SNDDST can be such a problem. Unfortunately, it's most probable that the iSeries has never had any e-mail client (for SMTP) installed. Just like a Windows system, if there is no e-mail client on the machine, then sending e-mail can be a bit of a problem. Unless you're a C programmer experienced with sockets or maybe a decent Java programmer... (COBOL? RPG?) When nothing else is available, SNDDST can be used. That assumes that the SNA/SMTP gateway is correctly configured and active and that SMTP is correctly configured, including external routing attributes, and that the SMTP server is started. Setting up a mail server is not trivial. Setting one up and talking through it with SNA functions is tricky enough that the clear majority of iSeries developers don't do it. Those that do get it done will usually resist tinkering with it. How many Windows developers enjoy installing and configuring e-mail servers on Windows? How often is it done on Windows by iSeries (or Unix/Linux or Mac) developers? Tom
    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following