Bug 693426 - fence_ipmilan returns incorrect status on monitor op if chassis is powered off
Summary: fence_ipmilan returns incorrect status on monitor op if chassis is powered off
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: fence-agents
Version: 5.6
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Marek Grac
QA Contact: Cluster QE
URL:
Whiteboard:
Depends On: 690735 693427 693428
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-04-04 15:57 UTC by Marek Grac
Modified: 2011-05-30 08:36 UTC (History)
4 users (show)

Fixed In Version: fence-agents-3.0.17-9.el5
Doc Type: Bug Fix
Doc Text:
Clone Of: 690735
Environment:
Last Closed: 2011-05-30 08:36:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:0834 0 normal SHIPPED_LIVE fence-agents bug fix and enhancement update 2011-05-30 08:35:50 UTC

Description Marek Grac 2011-04-04 15:57:01 UTC
+++ This bug was initially created as a clone of Bug #690735 +++

Description of problem:
There is a bug in fence_ipmilan agent: it exits with result code 2 on "monitor"/"status" command if chassis is powered off. Instead it should return 0 because "monitor" command should return fence device status, not chassis status.

Version-Release number of selected component (if applicable):
fence-agents-3.1.2-1.fc13.x86_64

--- Additional comment from bubble on 2011-03-25 04:24:11 EDT ---

Created attachment 487504 [details]
Patch to fix issue

--- Additional comment from mgrac on 2011-03-25 06:32:16 EDT ---

Created attachment 487518 [details]
Proposed patch

@Vladislav:

Thanks for reporting this bug. You are right, we should return 0 if the fence device is working. 

I have created a patch that should fix this. Yours patch will work correctly for 'monitor' but it will break 'status' as fence agent won't be able to return that chassis is powered off.

--- Additional comment from bubble on 2011-03-25 08:11:02 EDT ---

Looking through the code, it was probably just forgotten (ret is set to 0 for both on and off states but not used then).

I agree, your patch is cleaner.

Comment 4 errata-xmlrpc 2011-05-30 08:36:11 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 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-0834.html


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