Bug 590304 - cman-2.0.115-34.el5 /sbin/fence_vmware and /sbin/fence_vmware_helper
cman-2.0.115-34.el5 /sbin/fence_vmware and /sbin/fence_vmware_helper
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: cman (Show other bugs)
5.4
All Linux
urgent Severity high
: rc
: ---
Assigned To: Marek Grac
Cluster QE
: ZStream
Depends On:
Blocks: 606664
  Show dependency treegraph
 
Reported: 2010-05-08 14:25 EDT by Omer Faruk SEN
Modified: 2016-04-26 09:54 EDT (History)
7 users (show)

See Also:
Fixed In Version: cman-2.0.115-38.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-01-13 17:34:12 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Proposed patch of build system (1.30 KB, patch)
2010-05-19 11:17 EDT, Jan Friesse
no flags Details | Diff

  None (edit)
Description Omer Faruk SEN 2010-05-08 14:25:40 EDT
Description of problem:


cman-2.0.115-34.el5 package rhel 5.5 x86_64


How reproducible:

Just run 

/sbin/fence_vmware or 
/sbin/fence_vmware_helper


Steps to Reproduce:
Just run
/sbin/fence_vmware or 
/sbin/fence_vmware_helper


Actual results:

IF you run this files it doesn't get executed because there is a problem in the file itselt

Expected results:

It should run
Additional info:

When you execute those file because of the following lines it doesn't get executed


#BEGIN_VERSION_GENERATION
FENCE_RELEASE_NAME="2.0.115";
REDHAT_COPYRIGHT=("Copyright (C) Red Hat, Inc.  2004  All rights reserved.")
BUILD_DATE="(built Tue Mar 16 10:29:11 EDT 2010)";
#END_VERSION_GENERATION


If you run the command like

fence_vmware  -a IP_ADDR_OF_ESX -l user -p pass  -n vmware_guest_node_name

you get

fence_vmware_helper returned Can't modify constant item in scalar assignment at /sbin/fence_vmware_helper line 18, near ""2.0.115";"
Bareword "FENCE_RELEASE_NAME" not allowed while "strict subs" in use at /sbin/fence_vmware_helper line 18.
Bareword "REDHAT_COPYRIGHT" not allowed while "strict subs" in use at /sbin/fence_vmware_helper line 19.
Bareword "BUILD_DATE" not allowed while "strict subs" in use at /sbin/fence_vmware_helper line 20.
Execution of /sbin/fence_vmware_helper aborted due to compilation errors.

When you comment out those lines it runs perfectly.
Comment 1 Jan Friesse 2010-05-19 11:17:06 EDT
Created attachment 415157 [details]
Proposed patch of build system

Problem is in build system.
Comment 2 Jan Friesse 2010-05-19 11:19:55 EDT
Reassigning back to mgrac because bug is not in fence_vmware and he is responsible for commit which made problem (0886ca800604fa1db013446af27ef715e7658952).
Comment 3 Everett Bennett 2010-06-15 11:34:03 EDT
Do you have updated files to test?
Comment 5 Everett Bennett 2010-06-15 15:22:03 EDT
I made these changes:

m_vmime> pwd
/sbin
vm_vmime> diff fence_vmware fence_vmware.orig
30,31c30,31
< RELEASE_VERSION="2.0.115";
< REDHAT_COPYRIGHT="Copyright (C) Red Hat, Inc.  2004  All rights reserved.";
---
> FENCE_RELEASE_NAME="2.0.115";
> REDHAT_COPYRIGHT=("Copyright (C) Red Hat, Inc.  2004  All rights reserved.")
318,319d317
< 
< 
vm_vmime> diff fence_vmware_helper fence_vmware_helper.orig
15d14
< #my ($FENCE_RELEASE_NAME, $REDHAT_COPYRIGHT, $BUILD_DATE);
19,21c18,20
< $RELEASE_VERSION="2.0.115";
< $REDHAT_COPYRIGHT="Copyright (C) Red Hat, Inc.  2004  All rights reserved.";
< $BUILD_DATE="(built Tue Mar 16 10:29:11 EDT 2010)";
---
> FENCE_RELEASE_NAME="2.0.115";
> REDHAT_COPYRIGHT=("Copyright (C) Red Hat, Inc.  2004  All rights reserved.")
> BUILD_DATE="(built Tue Mar 16 10:29:11 EDT 2010)";
278,279d276
< 
< 


and I still get this error:

vm_vmime> fence_vmware -v -a 158.155.14.15 -l intec -p 3q9aa93q9 -n /vmfs/volumes/4c0952c2-b03ea556-9c41-0017a477000a/vmime/vmime.vmx
fence_vmware_helper --server '158.155.14.15' --username 'intec' --password '3q9aa93q9' --operation status --vmname '/vmfs/volumes/4c0952c2-b03ea556-9c41-0017a477000a/vmime/vmime.vmx'
Please install VI Perl API package to use this tool!
Perl error: Can't locate VMware/VIRuntime.pm in @INC (@INC contains: /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8 .) at (eval 1) line 1.
BEGIN failed--compilation aborted at (eval 1) line 1.

fence_vmware_helper returned Please install VI Perl API package to use this tool!
Perl error: Can't locate VMware/VIRuntime.pm in @INC (@INC contains: /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl /usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8 .) at (eval 1) line 1.
BEGIN failed--compilation aborted at (eval 1) line 1.


What is the "VI Perl API package" ?
Comment 6 Perry Myers 2010-06-15 15:37:09 EDT
fence_vmware relies on the VMware Perl API which is not (can not be) shipped with RHEL.  So you'll need to get this RPM from VMware and install it.  If you need assistance getting the RPM, please contact your VMware support rep.

Also, just to note, fence_vmware is Technical Preview and as of right now we do not have a timeline yet to fully support it for RHEL5.  One of the reasons that fence_vmware will likely remain Technical Preview is that it relies on a 3rd party package/RPM that we can't ship directly in RHEL.

We are investigating options for future versions of RHEL for doing vmware/virtualcenter/vsphere fencing that will not require the 3rd party APIs, but this is still being researched.
Comment 7 Everett Bennett 2010-06-15 15:44:18 EDT
I think it is working now.   Added '-x' and used root instead of other user....ooops forgot to specify -o status..... Good thing not production



vm_vmime> fence_vmware -v -a 158.155.14.15 -x -l root -p xxxxx -n vmime
fence_vmware_helper --server '158.155.14.15' --username 'root' --password '3q9aa93q9' --operation status --vmname 'vmime'
vmime:[dmx3918_lun96] vmime/vmime.vmx:poweredOn:connected

fence_vmware_helper --server '158.155.14.15' --username 'root' --password '3q9aa93q9' --operation off --vmname 'vmime'

What a pain.
Comment 8 Perry Myers 2010-06-15 19:51:37 EDT
(In reply to comment #7)
> I think it is working now.   Added '-x' and used root instead of other
> user....ooops forgot to specify -o status..... Good thing not production

yes, using the correct command line parameters and authentication username is a good thing
 
> 
> 
> vm_vmime> fence_vmware -v -a 158.155.14.15 -x -l root -p xxxxx -n vmime
> fence_vmware_helper --server '158.155.14.15' --username 'root' --password
> '3q9aa93q9' --operation status --vmname 'vmime'
> vmime:[dmx3918_lun96] vmime/vmime.vmx:poweredOn:connected
> 
> fence_vmware_helper --server '158.155.14.15' --username 'root' --password
> '3q9aa93q9' --operation off --vmname 'vmime'
> 
> What a pain.    

What is a pain?

If you have an issue above/beyond what this particular bug captures, please file another bug report through Red Hat support.  Otherwise I'm unclear as to what you are complaining about here.

Thanks
Comment 9 Everett Bennett 2010-06-16 09:35:52 EDT
(In reply to comment #8)
> (In reply to comment #7)
> > I think it is working now.   Added '-x' and used root instead of other
> > user....ooops forgot to specify -o status..... Good thing not production
> 
> yes, using the correct command line parameters and authentication username is a
> good thing
> 
> > 
> > 
> > vm_vmime> fence_vmware -v -a 158.155.14.15 -x -l root -p xxxxx -n vmime
> > fence_vmware_helper --server '158.155.14.15' --username 'root' --password
> > '3q9aa93q9' --operation status --vmname 'vmime'
> > vmime:[dmx3918_lun96] vmime/vmime.vmx:poweredOn:connected
> > 
> > fence_vmware_helper --server '158.155.14.15' --username 'root' --password
> > '3q9aa93q9' --operation off --vmname 'vmime'
> > 
> > What a pain.    
> 
> What is a pain?
> 
> If you have an issue above/beyond what this particular bug captures, please
> file another bug report through Red Hat support.  Otherwise I'm unclear as to
> what you are complaining about here.
> 
> Thanks    

The pain is after installing 'vmware-tools', you still need to install the 'api'.  There is no rpm, but a tar ball exists.  I think I have the latest sdk.

Nothing like having to hunt around the web to find everything you need when all  of the info should be in 1 place.  That's the pain.

http://www.wcborstel.com/article/creating-virtual-red-hat-cluster-vmware-vsphere.html

http://www.vmware.com/support/developer/viperltoolkit/
Comment 10 Perry Myers 2010-06-16 09:51:48 EDT
> The pain is after installing 'vmware-tools', you still need to install the
> 'api'.  There is no rpm, but a tar ball exists.  I think I have the latest sdk.
> 
> Nothing like having to hunt around the web to find everything you need when all
>  of the info should be in 1 place.  That's the pain.

Not much we can do about that given that VMware doesn't maintain these APIs as a part of Fedora or as an upstream/open source project.  If you could convince them to do that, then it would be feasible to pull the package into RHEL and then you wouldn't need to go to multiple places to get this working.

And as I mentioned, we are working on a way to remove the API dependency entirely but that work is still in progress.
Comment 11 Everett Bennett 2010-06-16 09:59:06 EDT
Thanks for your help.....someone else can find this ticket and hopefully get to the solution quicker.


Everett
Comment 12 Perry Myers 2010-06-16 10:06:55 EDT
Yeah, in addition I'm going to take the info and put it in a knowledge base article so that it's more centrally located rather than having to rely on google searching :)
Comment 13 Omer Faruk SEN 2010-06-17 01:26:22 EDT
It seems that RHEL 5.5 comes with new fence_vmware http://sources.redhat.com/cluster/wiki/VMware_FencingConfig and requires that vmware api so this bug is related with previous version of RHEL. I don't know how you guys at Redhat will act open that but since it there is 5.4z (with 18 months period) we can say this problem still persists.
Comment 15 Marek Grac 2010-06-18 05:00:54 EDT
@Omer:

This bug is present in RHEL 5.5 so I fixed it there and it will be part of next update. I did not check it in RHEL 5.4 but if there will be a request for such fix then it can be fixed in 5.4.z even if VMWare fence agent is just TechPreview
Comment 21 errata-xmlrpc 2011-01-13 17:34:12 EST
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 therefore 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-2011-0036.html

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