Permission Denied while executing DSSendMail

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

ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Permission Denied while executing DSSendMail

Post by ketfos »

Hi,
I am using a Notification Activity where i give the Mail paramters like
SMTP Mail Server Name, Sender address, Reciepient Address, Email Body.

When I execute the job named testseq which is - "Wait for File Activity and Send a Email Notification "
It gives error message "Error Executing command sendmail_testseq1.sh" - Execute permission denied

I use the same login for logging into the Unix box as I use for datastage job.
I am able to execute sendmail fucntion from Unix prompt.


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

Post by chulett »

:!: What version of DataStage? 7.5? What OS?

I'm having the exact same issue, but only on my test box where I'm running 7.5, not anywhere ever before on an older version. I have an open support ticket with Ascential and we're trying to track down the cause.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

Hi,
DataStage 7.5
OS UNIX HP

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

Post by chulett »

Funny... me. too. 7.5 on HP/UX 11i.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

Hi,
Yes, I executed the same job in Datastage 5.2 and it worked fine.


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

Post by ray.wurlod »

At UNIX, does the user executing the DataStage job have execute ("x") permission to sendmail_testseq1.sh ?

If not, use chmod a+x sendmail_testseq1.sh to ensure that this is the case.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

That's one question we've been trying to answer. The way this works seems to have fundamentally changed in 7.5. In the past, all of the leftover "sendmail_xxxxx.sh" files sat around in your Project directory forever and gave you something to look at. Now, the file is deleted after the process finishes. So, it builds a file - gives me an error that it can't execute the file - and then deletes it. :evil:

I've been stuffing some extra commands in the dssendmail_template.txt file to capture what may (or may not) be going on. All I've found at this point is the error occurs when running jobs as my "normal" user but everything is fine and dandy when running the jobs as "dsadm".

As best as I can tell, everything is set up "exactly the same as it has always been" under previous versions. I've communicated this to Ascential and they're checking into it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

Hi,
I logged in dsadm and executed the job again in 7.5.
But I got the same error message "permission denied"


Ketfos
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

Hi Craig,
You are correct. The job runs fine if you are logged as dsadm.
Yes unlike 5.x, the .sh file gets deleted after the execution of the job.

I went to the Unix box and logged in as regular user (not dsadm).
I created a empty file with name "sendmail_sequence1.sh

I logged into datastage as same user as above (not dsadm) and executed my job sequence1.

It ran with success. However as mentioned by you, sendmail_sequence1.sh file gets deleted.

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

Post by ray.wurlod »

Sounds like "they" have to add a chmod to the process. :shock:
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

They've added something. :roll:

Now I'm wondering if this problem may be specific to HP/UX. :? I'd be curious if anyone out there is using 7.5 on UNIX platforms (HP or otherwise) and is not having or did not have any problems with sendmail? Did you need to do anything different with this version to get it to work?
-craig

"You can never have too many knives" -- Logan Nine Fingers
danjm
Participant
Posts: 34
Joined: Tue Sep 09, 2003 8:44 am
Location: Canada
Contact:

Deleted file

Post by danjm »

It's been a while since I've done any UNIX work but I'm just wondering if you could set the DataStage permissions on the directory where that file is created to not allow file deletions, run the job (DS would error out on the deletion attempt) and you might then be able to inspect the file after the failure??
Dan Marshall
Alberta Education
Edmonton, AB
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

For what it's worth, Ascential Support was finally able to reproduce this problem in-house. If there is an actual resolution, I'll post it here as well. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

How do you set permission on file not to allow deletion as suggested by Dan?

Ketfos
ketfos
Participant
Posts: 562
Joined: Mon May 03, 2004 8:58 pm
Location: san francisco
Contact:

Post by ketfos »

Hi Dan,
The datastage job has to create, read,write and execute to this file, before it deletes it.

How do set the permission so that it writes to the file and not delete it.


Ketfos
Post Reply