Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-948

Writers on two machines over NFS can hit FNFE due to stale NFS client caching

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.1
    • Fix Version/s: 2.3
    • Component/s: core/index
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      Issue spawned from this thread:

      http://www.gossamer-threads.com/lists/lucene/java-user/50680

      When IndexFileDeleter lists the directory, looking for segments_X
      files to load, if it hits a FNFE on opening such a file it should
      catch this and treat it as if the file does not exist.

      On NFS (and possibly other file systems), a directory listing is not
      guaranteed to be "current"/coherent. Specifically, if machine #1 has
      just removed file "segments_n" and shortly thereafer machine #2 does a
      dir listing, it's possible (likely?) that the dir listing will still
      show that segments_n exists.

      I think the fix is simple: catch the FNFE and just handle it as if the
      segments_n does not in fact exist.

      1. LUCENE-948.patch
        2 kB
        Michael McCandless
      2. LUCENE-948.take2.patch
        4 kB
        Michael McCandless
      3. LUCENE-948-core-2.2.0.jar
        526 kB
        Michael McCandless
      4. LUCENE-948-core-2.2.0.take2.jar
        526 kB
        Michael McCandless

        Activity

        Hide
        mikemccand Michael McCandless added a comment -

        Attached patch & new 2.2.0 JAR that has this fix.

        Show
        mikemccand Michael McCandless added a comment - Attached patch & new 2.2.0 JAR that has this fix.
        Hide
        mikemccand Michael McCandless added a comment -

        Another iteration, to just add more verbosity when infoStream is set.

        Show
        mikemccand Michael McCandless added a comment - Another iteration, to just add more verbosity when infoStream is set.
        Hide
        mikemccand Michael McCandless added a comment -

        Fixed on trunk (2.3).

        Show
        mikemccand Michael McCandless added a comment - Fixed on trunk (2.3).

          People

          • Assignee:
            mikemccand Michael McCandless
            Reporter:
            mikemccand Michael McCandless
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development