Bug 517860 - fence_apc fails to fence node: Failed: Unable to obtain correct plug status or plug is not available
Summary: fence_apc fails to fence node: Failed: Unable to obtain correct plug status o...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: fence-agents
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Marek Grac
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 525105 532916
TreeView+ depends on / blocked
 
Reported: 2009-08-17 14:28 UTC by Abhijith Das
Modified: 2009-11-04 10:30 UTC (History)
1 user (show)

Fixed In Version: cluster 3.0.3 stable
Clone Of:
: 525105 532916 (view as bug list)
Environment:
Last Closed: 2009-10-02 13:13:21 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Abhijith Das 2009-08-17 14:28:28 UTC
Spoke with marx on IRC and changing the regex in /usr/sbin/fence_apc fixed it.

--- fence_apc.broken    2009-08-17 09:28:34.000000000 -0500
+++ fence_apc   2009-08-17 09:28:48.000000000 -0500
@@ -70,7 +70,7 @@ def get_power_status(conn, options):
                while True:
                        exp_result = conn.log_expect(options, [ options["-c"],  "Press <ENTER>" ], SHELL_TIMEOUT)
                        lines = conn.before.split("\n");
-                       show_re = re.compile('^\s*(\d+)- (.*?)\s+(ON|OFF)\s*$')
+                       show_re = re.compile('^\s*(\d+)- (.*?)\s+(ON|OFF)\s*')
                        for x in lines:
                                res = show_re.search(x)
                                if (res != None):

Comment 1 Marek Grac 2009-08-17 14:47:27 UTC
Device info and how line differs:

<abhi`> American Power Conversion               Web/SNMP Management Card AOS     v2.5.4
<abhi`> (c) Copyright 2000 All Rights Reserved  MasterSwitch plus APP            v2.0.0
<abhi`> -------------------------------------------------------------------------------


    1- Outlet 1:1  shell-01                ON        Graceful Shutdown


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