Bug 172310 - Pass service name to script resource invocation to let the script know which service is being controlled
Summary: Pass service name to script resource invocation to let the script know which...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Cluster Suite
Classification: Retired
Component: rgmanager
Version: 4
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Lon Hohberger
QA Contact: Cluster QE
URL:
Whiteboard:
Depends On:
Blocks: 164915
TreeView+ depends on / blocked
 
Reported: 2005-11-02 17:08 UTC by Jiho Hahm
Modified: 2009-04-16 20:18 UTC (History)
1 user (show)

Fixed In Version: RHBA-2006-0173
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-06-21 13:53:33 UTC
Embargoed:


Attachments (Terms of Use)
Make script.sh set service name in env of script being invoked (632 bytes, patch)
2005-11-02 17:08 UTC, Jiho Hahm
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2006:0173 0 normal SHIPPED_LIVE rgmanager bug fix update 2006-01-06 05:00:00 UTC

Description Jiho Hahm 2005-11-02 17:08:28 UTC
Description of problem:

I have a custom <script> resource that needs to do some setup work specific to
the cluster <service> being started.  Update script.sh (patch attached) to pass
service name as environment variable.  The patch will let the script see service
name as OCF_RESKEY_service_name env var.

Version-Release number of selected component (if applicable):

    rgmanager-1.39.9-0

Comment 1 Jiho Hahm 2005-11-02 17:08:28 UTC
Created attachment 120649 [details]
Make script.sh set service name in env of script being invoked

Comment 3 Lon Hohberger 2005-11-21 21:46:41 UTC
Fixes in CVS - the inheritance uses the new-ish "%" delimiter so that we only
inherit the "name" attribute if it is, in fact, from a parent service resource.

Comment 5 Red Hat Bugzilla 2006-01-06 20:23:33 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0173.html


Comment 6 Jiho Hahm 2007-06-20 19:23:02 UTC
Hi, I'm reopening this bug because the service name is not passed when the
script resource is not a direct child element of <service>.  With the resource
dependency feature implemented in bug 212121, <script> resources can (and
usually will be) one or more levels removed from <service> because the
application being controlled by the script will depend on other resources like
IP address and filesystems.

Comment 7 Lon Hohberger 2007-06-21 13:48:48 UTC
Like in bug 231521 for rhel5?

Comment 8 Lon Hohberger 2007-06-21 13:53:33 UTC
I've created a different bug for this:

https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=245171



Comment 9 Jiho Hahm 2007-06-21 18:08:53 UTC
Yes, it's the same issue.  Thanks.


Note You need to log in before you can comment on or make changes to this bug.