Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-3017

Hazard pointer race with page replace causes error

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Critical - P2 Critical - P2
    • WT2.9.0, 3.2.12, 3.4.0-rc4
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Storage 2016-11-21

      Setting a hazard pointer consists of:

      1. reading ref->page and setting hp->page
      2. full barrier
      3. reading ref->page checking it is still equal to hp->page
      4. checking ref->state == WT_REF_MEM.

      However, if eviction cannot evict all of the changes on a page and decides to replace the page, there is a window where ref->page == NULL. If the page replacement completes in between steps 3 and 4 above, the call to __wt_hazard_set can report success but publish a NULL hazard pointer.

            Assignee:
            michael.cahill@mongodb.com Michael Cahill (Inactive)
            Reporter:
            michael.cahill@mongodb.com Michael Cahill (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: