Bug 607229 - gfs2_edit restoremeta should not return 0 on failure
Summary: gfs2_edit restoremeta should not return 0 on failure
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: gfs2-utils
Version: 5.5
Hardware: All
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Robert Peterson
QA Contact: Cluster QE
URL:
Whiteboard:
Depends On:
Blocks: 607321
TreeView+ depends on / blocked
 
Reported: 2010-06-23 14:48 UTC by Jaroslav Kortus
Modified: 2011-01-13 23:21 UTC (History)
4 users (show)

Fixed In Version: gfs2-utils-0.1.62-25.el5
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 607321 (view as bug list)
Environment:
Last Closed: 2011-01-13 23:21:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Patch to fix the problem (765 bytes, patch)
2010-06-23 19:43 UTC, Robert Peterson
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:0135 0 normal SHIPPED_LIVE gfs2-utils bug fix update 2011-01-12 19:26:41 UTC

Description Jaroslav Kortus 2010-06-23 14:48:56 UTC
Description of problem:
gfs2_edit restoremeta <metadata> <device> returns 0 even if the metadata could not be fully written to the destination device.

Version-Release number of selected component (if applicable):
gfs2-utils-0.1.62-20.el5

How reproducible:

gfs2_edit restoremeta datavol03.meta /dev/vedder/vedder0 ; echo $?
There are 53311488 blocks of 4096 bytes in the destination file system.

440846 metadata blocks (1722MB) restored.    Error: File system is too small to restore this metadata.
File system is 53311488 blocks, Restore block = 53345526
File datavol03.meta-bz519049 restore error.
0

  
Actual results:
exit code == 0

Expected results:
exit code != 0 if error has occured

Additional info:

Comment 1 Robert Peterson 2010-06-23 14:59:28 UTC
This should be easy to fix; requesting ack flags for inclusion
into 5.6.

Comment 2 Robert Peterson 2010-06-23 19:43:03 UTC
Created attachment 426372 [details]
Patch to fix the problem

Here is the patch to fix the problem.  I tested it on roth-01.

Comment 3 Robert Peterson 2010-06-29 14:19:45 UTC
I pushed the patch to the RHEL56 branch of the cluster git
tree for inclusion into RHEL 5.6.  The upstream equivalent
has already been pushed by way of another bugzilla record.
This was tested on roth-01.  Changing status to POST until
we build it.

Comment 4 Robert Peterson 2010-09-17 15:58:00 UTC
Build 2768496 successful.  Changing status to Modified.
This fix is in gfs2-utils-0.1.62-25.el5.

Comment 7 errata-xmlrpc 2011-01-13 23:21:02 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-0135.html


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