[Bugs] [Bug 1630141] New: libgfchangelog: History API fails
bugzilla at redhat.com
bugzilla at redhat.com
Tue Sep 18 05:21:33 UTC 2018
https://bugzilla.redhat.com/show_bug.cgi?id=1630141
Bug ID: 1630141
Summary: libgfchangelog: History API fails
Product: GlusterFS
Version: 4.1
Component: changelog
Assignee: bugs at gluster.org
Reporter: khiremat at redhat.com
CC: bugs at gluster.org, sunkumar at redhat.com
Depends On: 1622549
Blocks: 1627639
+++ This bug was initially created as a clone of Bug #1622549 +++
Description of problem:
If requested start time and end time doesn't fall into
first HTIME file, then history API fails even though
continuous changelogs are avaiable for the requested range
in other HTIME files. This is induced by changelog disable
and enable which creates fresh HTIME index file.
Version-Release number of selected component (if applicable):
mainline
How reproducible:
Always
Steps to Reproduce:
1. Setup gluster volume and let the I/O happen
2. Enable changelog
3. sleep for some time
4. Disable changelog
5. sleep for sometime
6. Enable changelog
7. Use the sample c program attached to query history API with start time after
step 6
Actual results:
History fails
Expected results:
History API should not fail if continuous changelogs are available even if it's
second HTIME file.
Additional info:
--- Additional comment from Kotresh HR on 2018-08-27 08:56 EDT ---
Steps to run the program.
1. Place both header file and C program attached in a directory
2. Compile
gcc -o get-history get-history.c -lgfchangelog
3. Run
get-history <start-time> <end-time>
--- Additional comment from Worker Ant on 2018-08-27 09:18:10 EDT ---
REVIEW: https://review.gluster.org/21016 (libgfchangelog: Fix history
changelog) posted (#1) for review on master by Kotresh HR
--- Additional comment from Worker Ant on 2018-08-31 09:29:16 EDT ---
COMMIT: https://review.gluster.org/21016 committed in master by "Amar Tumballi"
<amarts at redhat.com> with a commit message- libgfchangelog: Fix changelog
history API
Problem:
If requested start time and end time doesn't fall into
first HTIME file, then history API fails even though
continuous changelogs are avaiable for the requested range
in other HTIME files. This is induced by changelog disable
and enable which creates fresh HTIME index file.
Cause and Analysis:
Each HTIME index file represents the availability of
continuous changelogs. If changelog is disabled and enabled,
a new HTIME index file is created represents non availability
of continuous changelogs. So as long as the requested start
and end falls into single HTIME index file and not across,
history API should succeed.
But History API checks for the changelogs only in first
HTIME index file and errors out if not available.
Fix:
Check in all HTIME index files for availability of continuous
changelogs for requested change.
fixes: bz#1622549
Change-Id: I80eeceb5afbd1b89f86a9dc4c320e161907d3559
Signed-off-by: Kotresh HR <khiremat at redhat.com>
Referenced Bugs:
https://bugzilla.redhat.com/show_bug.cgi?id=1622549
[Bug 1622549] libgfchangelog: History API fails
https://bugzilla.redhat.com/show_bug.cgi?id=1627639
[Bug 1627639] libgfchangelog: History API fails
--
You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.
More information about the Bugs
mailing list