ZooKeeper
  1. ZooKeeper
  2. ZOOKEEPER-1156

Log truncation truncating log too much - can cause data loss

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 3.3.3
    • Fix Version/s: 3.3.4, 3.4.0
    • Component/s: quorum, server
    • Labels:
      None

      Description

      The log truncation relies on position calculation for a particular zxid to figure out the new size of the log file. There is a bug in PositionInputStream implementation which skips counting the bytes in the log which have value 0. This can lead to underestimating the actual log size. The log records which should be there can get truncated, leading to data loss on the participant which is executing the trunc.

      Clients can see different values depending on whether they connect to the node on which trunc was executed.

      1. ZOOKEEPER-1156.patch
        2 kB
        Vishal Kathuria

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Vishal Kathuria
            Reporter:
            Vishal Kathuria
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 24h
              24h
              Remaining:
              Remaining Estimate - 24h
              24h
              Logged:
              Time Spent - Not Specified
              Not Specified

                Development