Page 2 of 2

Posted: Fri Mar 21, 2008 6:51 am
by chulett
They don't seem to want to listen to either of us, Arnd.

Posted: Fri Mar 21, 2008 6:53 am
by mikegohl
I also like Craigs advise about sourcing the dsenv file in the script. You could get this error if you don't:

error while loading shared libraries: libvmdsapi.so: cannot open shared object file: No such file or directory

By the way, the return code is 127 when you get this error. Someone also suggested getting the standard error from the script too. This may help.

Posted: Fri Mar 21, 2008 7:16 am
by sri75
ArndW wrote:add "-mode NORMAL" to your command.
Hi Arnd/Craig..

I didnt mean to ignore you...

If you look at my previous post,, in my code I have included "-mode Normal" in my command.. but still then it did not return any value or error code..

Here is the command we used in the shell script file..

Code: Select all

dsjob -run -mode NORMAL -jobstatus -wait  HCM89_EPM90DEV SEQ_J_Stage_PS_ABS_CLASS_TBL 
RETURN_VALUE=$? 
echo "Return Value $RETURN_VALUE" 

we are getting output as: 
dsjob -run -jobstatus -wait    
Return Value 127
As you have mentioned in previous posts, Process scheduler doesnt even recognise the dsjob command..so how can it execute the -mode NORMAL?

did I include mode NORMAL correctly?

Craig,
Can you explain in brief about sourcing dsenv file? I did not understand what you meant..

Thanks a lot for your help.. and again I am not ignoring you guys..

Posted: Fri Mar 21, 2008 7:25 am
by ArndW
Here is the command we used in the shell script file..

Code: Select all

dsjob -run -mode NORMAL -jobstatus -wait  HCM89_EPM90DEV SEQ_J_Stage_PS_ABS_CLASS_TBL 
RETURN_VALUE=$? 
echo "Return Value $RETURN_VALUE" 

we are getting output as: 
dsjob -run -jobstatus -wait    
Return Value 127
I don't think you put the command in - look at your output...

Posted: Fri Mar 21, 2008 8:08 am
by chulett
Bare bones, add something like this to your script:

Code: Select all

cd `cat /.dshome` && . ./dsenv
And let us know if that helps.

Posted: Fri Mar 21, 2008 8:11 am
by chulett
sri75 wrote:If you look at my previous post,, in my code I have included "-mode Normal" in my command.. but still then it did not return any value or error code..
Actually, when we looked at your post previous to ours, it is not included. Hence the comment.

Posted: Fri Mar 21, 2008 8:26 am
by sri75
chulett wrote:Bare bones, add something like this to your script:

Code: Select all

cd `cat /.dshome` && . ./dsenv
And let us know if that helps.
Hi Craig,, still its not working and here is the code I gave

Code: Select all

cd `cat /.dshome` && . ./dsenv
echo "DATE and Time Is:"
date
echo "Hello"
dsadmin -listprojects
RETURN_VALUE=$?
echo "Return Value $RETURN_VALUE"
Return value is still 127

Did I miss some thing?

Posted: Fri Mar 21, 2008 9:06 am
by chulett
Hard to say. What happens when you execute that code snippet from the command line, does it work? And we'll never know what's going wrong in your script if you don't add better debugging information.

It's been mentioned as least three times that you need to capture 'standard error' in your script so you can see what is going wrong, something more than just the 127 return code.

Posted: Fri Mar 21, 2008 3:03 pm
by deanwalker
127 from dsadmin now, not dsjob.
I suggest that you print the PATH, probably even the whole environment,
to see how it differs from the one used when running manually.

Posted: Fri Mar 21, 2008 4:52 pm
by ray.wurlod
Use -jobstatus OR -wait, not both.