Bug 732004 - Improve async store error messages for null .jinf file during recovery
Summary: Improve async store error messages for null .jinf file during recovery
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-cpp
Version: Development
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: 2.3
: ---
Assignee: Kim van der Riet
QA Contact: MRG Quality Engineering
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-08-19 12:40 UTC by Kim van der Riet
Modified: 2013-01-02 18:58 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-20 14:46:02 UTC


Attachments (Terms of Use)

Description Kim van der Riet 2011-08-19 12:40:22 UTC
Attempting to recover a store which contains a zero-length .jinf file (which can occur if the partition containing the store runs out of space) results in confusing error messages which are not only truncated somehow (this needs to be investigated as well) but are unrelated to the actual problem.

Currently, a null .jinf file results in a validation error for the journal version. This occurs because the struct for the jinf data is initialized such that the version is zero, and is set in the subsequent read of the file. If the read does not contain a valid version string, then the zero version remains and is caught during validation as an invalid version.

Insert a check for zero-length .jinf files and create an error code for this condition.

Comment 1 Kim van der Riet 2011-08-19 14:16:21 UTC
Added a new exception JERR_JINF_ZEROLENFILE which is thrown if the .jinf file is zero length.

Also improved the format of the validation messages slightly, including an error which caused the full message to be truncated.

Fixed in r.4471.

Comment 2 Kim van der Riet 2011-08-19 14:21:27 UTC
For reference, the new error is formatted as follows:

2011-08-19 10:11:42 critical Unexpected error: Queue qpid-perftest0: recoverQueues() failed: jexception 0x0c0a jinf::read() threw JERR_JINF_ZEROLENFILE: Journal info file zero length (/path/to/jrnl//JournalData.jinf) (MessageStoreImpl.cpp:820)

Comment 3 Ted Ross 2012-03-29 20:08:48 UTC
Fixed prior to 0.14 rebase

Comment 4 Leonid Zhaldybin 2012-05-10 13:45:19 UTC
CLOSED/CRELEASE -> ASSIGNED -> ON_QA
The defect has to go through QA process.

Comment 5 Leonid Zhaldybin 2012-05-10 13:53:20 UTC
Tested on RHEL5.8 and RHEL6.2 on both main architectures (i386 and
x86_64).
Packages used for testing:

RHEL6.2:
python-qpid-0.14-7.el6_2
python-qpid-qmf-0.14-7.el6_2
qpid-cpp-client-0.14-14.el6_2
qpid-cpp-client-devel-0.14-14.el6_2
qpid-cpp-client-devel-docs-0.14-14.el6_2
qpid-cpp-server-0.14-14.el6_2
qpid-cpp-server-devel-0.14-14.el6_2
qpid-cpp-server-store-0.14-14.el6_2
qpid-cpp-server-xml-0.14-14.el6_2
qpid-java-client-0.14-3.el6
qpid-java-common-0.14-3.el6
qpid-java-example-0.14-3.el6
qpid-qmf-0.14-7.el6_2
qpid-tools-0.14-2.el6_2

RHEL5.8:
python-qpid-0.14-6.el5
python-qpid-qmf-0.14-9.el5
qpid-cpp-client-0.14-14.el5
qpid-cpp-client-devel-0.14-14.el5
qpid-cpp-client-devel-docs-0.14-14.el5
qpid-cpp-client-ssl-0.14-14.el5
qpid-cpp-server-0.14-14.el5
qpid-cpp-server-cluster-0.14-14.el5
qpid-cpp-server-devel-0.14-14.el5
qpid-cpp-server-ssl-0.14-14.el5
qpid-cpp-server-store-0.14-14.el5
qpid-cpp-server-xml-0.14-14.el5
qpid-java-client-0.14-3.el5
qpid-java-common-0.14-3.el5
qpid-java-example-0.14-3.el5
qpid-qmf-0.14-9.el5
qpid-qmf-devel-0.14-9.el5
qpid-tools-0.14-2.el5

qpidd is throwing the exception JERR_JINF_ZEROLENFILE now in case *.jinf file has zero length.

-> VERIFIED


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