code: public void updateDataSegmentPosition(long iPosition, final int iDataSegmentId, final long iDataSegmentPosition)
        throws IOException {
      iPosition = iPosition * RECORD_SIZE;
  
      acquireExclusiveLock();
      try {
  
        final long[] pos = fileSegment.getRelativePosition(iPosition);
  
        final OFile f = fileSegment.files[(int) pos[0]];
        long p = pos[1];
  
        f.writeShort(p, (short) iDataSegmentId);
        f.writeLong(p += OBinaryProtocol.SIZE_SHORT, iDataSegmentPosition);
  
      } finally {
        releaseExclusiveLock();
      }
    }
docs: Update position in data segment (usually on defrag)
  
  @throws IOException