code: public void snapshotAppendOnlyFile(File file) throws IOException {
          // write filename
          String name = file.getName();
          writeUTF(name);
          // write current file length
          writeLong(file.length());
          File auxDir = getAuxiliaryDirectory();
          if(!auxDir.exists()) {
              FileUtils.ensureWriteableDirectory(auxDir);
          }
          File destination = new File(auxDir,name);
          hardlinkOrCopy(file, destination);
      }
docs: Store a snapshot of an object's supporting file to the
  current auxiliary directory. Should only be used for
  files which are strictly appended-to, because it tries
  to use a "hard link" where possible (meaning that
  future edits to the original file's contents will
  also affect the snapshot).
  
  Remembers current file extent to allow a future restore
  to ignore subsequent appended data.
  
  @param file
  @throws IOException