Revision 98ec75d6

b/lib/hypervisor/hv_kvm.py
94 94
    dirs = [(dname, constants.RUN_DIRS_MODE) for dname in self._DIRS]
95 95
    utils.EnsureDirs(dirs)
96 96

  
97
  def _InstancePidFile(self, instance_name):
98
    """Returns the instance pidfile.
99

  
100
    """
101
    pidfile = "%s/%s" % (self._PIDS_DIR, instance_name)
102
    return pidfile
103

  
97 104
  def _InstancePidAlive(self, instance_name):
98 105
    """Returns the instance pid and pidfile
99 106

  
100 107
    """
101
    pidfile = "%s/%s" % (self._PIDS_DIR, instance_name)
108
    pidfile = self._InstancePidFile(instance_name)
102 109
    pid = utils.ReadPidFile(pidfile)
103 110
    alive = utils.IsProcessAlive(pid)
104 111

  
......
289 296
    """Generate KVM information to start an instance.
290 297

  
291 298
    """
292
    pidfile, pid, alive = self._InstancePidAlive(instance.name)
299
    pidfile  = self._InstancePidFile(instance.name)
293 300
    kvm = constants.KVM_PATH
294 301
    kvm_cmd = [kvm]
295 302
    kvm_cmd.extend(['-m', instance.beparams[constants.BE_MEMORY]])

Also available in: Unified diff