[ClusterLabs] Two bugs in fence_ec2 script

Steve Marshall steve.marshall at weather.com
Thu Feb 4 14:46:55 UTC 2016


I've found two bugs in the fence_ec2 script found in this RPM:
fence_ec2-0.1-0.10.1.x86_64.rpm

I believe this is the latest and greatest, but I may be wrong.  I'm not
sure where to post these fixes, so I'm starting here.  If there is a better
place to post, please let me know.

The errors are:
1. The tag attribute does not default to "Name", as specified in the
documentation
2. The script does not accept attribute settings from stdin

#1 is not critical, since tag=Name can be specified explicitly when setting
up a stonith resource.  However, #2 is very important, since stonith_admin
(and I think most of pacemaker) passes arguments to fencing scripts via
stdin.  Without this fix, fence_ec2 will not work properly via pacemaker,
that is:

This command works....
fence_ec2 --action=metadata

...but this alternate version of same command does not:
echo "action=metadata" | fence_ec2

The fixes are relatively trivial.  The version of fence_ec2 from the RPM is
attached as fence_ec2.old.  My modified version is attached as
fence_ec2.new.  I've also attached the RPM that was the source for
fence_ec2.old.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20160204/f2677097/attachment-0003.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fence_ec2-0.1-0.10.1.x86_64.rpm
Type: application/x-rpm
Size: 6619 bytes
Desc: not available
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20160204/f2677097/attachment-0003.rpm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fence_ec2.old
Type: application/octet-stream
Size: 10889 bytes
Desc: not available
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20160204/f2677097/attachment-0006.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fence_ec2.new
Type: application/octet-stream
Size: 11005 bytes
Desc: not available
URL: <https://lists.clusterlabs.org/pipermail/users/attachments/20160204/f2677097/attachment-0007.obj>


More information about the Users mailing list