anchor.diff:              {Fd, InitialName}
       end.
   
  -upgrade_state({file, Fd, IsSys, Eof, DbPid}) ->
  -    Limit = get_pread_limit(),
  -    #file{fd=Fd, is_sys=IsSys, eof=Eof, db_pid=DbPid, pread_limit=Limit};
  +upgrade_state(#file{db_monitor=DbPid}=File) when is_pid(DbPid) ->
  +    unlink(DbPid),
  +    Ref = monitor(process, DbPid),
  +    File#file{db_monitor=Ref};
   upgrade_state(State) ->
       State.
   
  
positive.code: % server functions
  
  init({Filepath, Options, ReturnPid, Ref}) ->
      process_flag(trap_exit, true),
      OpenOptions = file_open_options(Options),
      Limit = get_pread_limit(),
      IsSys = lists:member(sys_db, Options),
  
negative.code:     fd,
      is_sys,
      eof = 0,
      db_monitor,
      pread_limit = 0
  }).
  
  