1836634 Members
1514 Online
110102 Solutions
New Discussion

SG test_return ??

 
SOLVED
Go to solution
MikeL_4
Super Advisor

SG test_return ??

Within our package start/stop script we start our applications and then do a test_return 56 and within that we execute:
56)
print "\tERROR: Application Start "
print "\tERROR: Failed to start/stop customer commands"
halt_services
customer_defined_halt_cmds
disown_dtc
remove_ip_address
verify_ha_nfs stop
umount_fs
deactivate_volume_group
deactivate_disk_group
to_exit=1
;;

If at this point I don't want to have SG start the halt package process, but rather just send out a notification that errors occured, can I change this to something like:
54)
print "\tERROR: Application Start "
print "\tERROR: Failed to start/stop customer commands"
wall message_file
to_exit=0
;;

This would allow the already started databases to remain up and then the applications group can fix the application startup problem.
3 REPLIES 3
Kent Ostby
Honored Contributor
Solution

Re: SG test_return ??

Mike -- That should work.
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"
MikeL_4
Super Advisor

Re: SG test_return ??

thanks
Kent Ostby
Honored Contributor

Re: SG test_return ??

Mike --

The actual key to the script stopping is "exit_value".

So if some OTHER aspect of the start up fails and to_exit is set (which will trigger exit_value being set) or exit_value is set directly, then the package will still fail.

However, your change should keep the script from failing within that particular part of the package startup.
"Well, actually, she is a rocket scientist" -- Steve Martin in "Roxanne"