let move_ungate fname restore =
  Unix.rename restore fname