def BackupFile(node, path):
  vpath = MakeNodePath(node, path)

  cmd = ("tmp=$(mktemp .gnt.XXXXXX --tmpdir=$(dirname %s)) && "
         "[[ -f \"$tmp\" ]] && "
         "cp %s $tmp && "
         "echo $tmp") % (utils.ShellQuote(vpath), utils.ShellQuote(vpath))

  # Return temporary filename
  result = GetCommandOutput(node, cmd).strip()

  print "Backup filename: %s" % result

  return result
Sets the thread ID and returns the callable and args for this request.
dataset/ETHPy150Open ganeti/ganeti/qa/qa_utils.py/BackupFile--crossover with--dataset/ETHPy150Open AppScale/appscale/AppServer/google/appengine/runtime/background.py/_BackgroundRequest.WaitForCallable