[Material deleted]
> But I found there was an error in our "/home/tsm/dsmc_archive.sh" shell >
script, that caused it to fail. The script looks like :
>
> dsmc archive -archmc=migartion_archive -subdir=yes -quiet -archsyml=no \
> /sapmnt/T21/
> dsmc archive -archmc=migration_archive -subdir=yes -quiet -archsyml=no \
> /usr/sap/put/
>
> In the first line of the script, I made a typo, specifiying an inexistant
> management class, therefore the script failed !
>
> How is it possible that TSM returns me "completed", as this script failed?
> Is it a bug ? Is there any way checkin the real status of the schedule,
> without logging on the node to verify dsmsched.err ?

In the absence of an exit statement, the exit status of a shell script is the
exit status of the last command executed. Since the second and last dsmc
command in your script ended with a zero exit status, the script ended with a
zero exit status. TSM quite reasonably reported this as successful completion.
If you want failures reported reliably you will need to add some explicit
error checking to the script.

Reply via email to