DSSendMail Problem

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
endyl13
Premium Member
Premium Member
Posts: 44
Joined: Tue Jun 25, 2002 12:47 am
Location: Qatar
Contact:

DSSendMail Problem

Post by endyl13 »

Hi all,

I am trying to create a job with an After-Job Routine to Send Email for notification. I's using DStage 5.2 on Solaris.
Everytime I run the job, it always fail.
I tried to test the DSSendMail function by using DSSendMailTester Routine, the same error come:

TEST #1
*******

Arg1 = EndyL@bot.or.th
Arg2 = EndyL@bot.or.th
Arg3 = Test ETL
Arg4 = SMARTBMA1
Arg5 = Tester

Test completed.

DSLogWarn called from : DSSendMail
Message to be logged is...
> Error when executing command: "sendmail_62046.sh"
> *** Output from command was: ***
> SH: sendmail_62046.sh: not found
>
> The following parameters in the call to DSSendMail were not mentioned in the file 'dssendmail_template.txt': server
>
> Contents of command file:
> #! /usr/bin/sh
> /usr/sbin/sendmail -t To: EndyL@bot.or.th
> Subject: Test ETL
>
> Tester
> ////

Result = Error when executing external command

I checked where the 'sendmail' command is, and I found out it's not in /usr/sbin directory, instead it's in /usr/lib directory.
I have no UNIX knowledge, Do I need to configure the configuration in the Solaris?

Kindly advise...


Regards

ND
luca
Participant
Posts: 81
Joined: Wed May 14, 2003 11:34 pm

Post by luca »

Hi !
Your problem should be solve by creating a link.
see ln command in Unix (by doing: man ln)
endyl13
Premium Member
Premium Member
Posts: 44
Joined: Tue Jun 25, 2002 12:47 am
Location: Qatar
Contact:

Post by endyl13 »

Hi Luca,

Thanks for your respond, but can you be more specific? I've looked at the 'ln' help, but I still don't know what is the problem, and what kind of link that I need to create.
Can you be more detail please? My UNIX knowledge is almost non existence [^]

Thanks


Regards

ND
endyl13
Premium Member
Premium Member
Posts: 44
Joined: Tue Jun 25, 2002 12:47 am
Location: Qatar
Contact:

Post by endyl13 »

I revised, I just read the whole help, what you mean I need to create a link from /usr/lib to /usr/sbin
I've tried, but I don't have the permission to create the link [V]
I will ask the admin to do it.

Thanks


Regards

ND
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

I'm not sure this is a good idea, it basically means it will always treat any reference to "/usr/sbin" as a reference to "/usr/lib".

Can't you go in and edit the sendmail function to call the script correctly? Either that or create a link from 'sendmail' in /usr/sbin to the real one in /usr/lib... you'd still need an admin to do it for you, but this would be much safer.

-craig
endyl13
Premium Member
Premium Member
Posts: 44
Joined: Tue Jun 25, 2002 12:47 am
Location: Qatar
Contact:

Post by endyl13 »

Hi Craig,
How to 'go in and edit' the DSSendMail routine?
I couldn't find any way of doing it.



Regards

ND
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Sorry, it was more of a question than a statement that it can be done... I'd just be surprised if it can't. [:)] Perhaps someone from another part of the world can pipe in with the details on that, as I'm at home and don't have a client installed.

Having someone create a soft link to sendmail *will* work! On my system the actual executable lives in /usr/sbin and there is a soft link to /usr/sbin/sendmail in /usr/lib. Just curious, but if you have "no UNIX knowledge", as you *sure* about where sendmail really lives? Have you approached your admins for help?

-craig
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Source for DSSendMail is not provided. You can look at the Routine called DSSendMailTester to get a good idea about how DSSendMail works.

Ray Wurlod
Education and Consulting Services
ABN 57 092 448 518
idocrm
Participant
Posts: 17
Joined: Wed Jul 23, 2003 9:41 pm

Post by idocrm »

I was having the same problem before. What you need to do is to search for a file with the name of 'dssendmail_template.txt' and change '/usr/sbin/sendmail' to '/usr/lib/sendmail'. There are some comments come with dssendmail_template.txt. This txt file should be under your project directory. Hope that helps.
Post Reply