Revision c4de9b7a lib/cmdlib.py
b/lib/cmdlib.py | ||
---|---|---|
6080 | 6080 |
|
6081 | 6081 |
_StartInstanceDisks(self, instance, force) |
6082 | 6082 |
|
6083 |
result = self.rpc.call_instance_start(node_current, instance, |
|
6084 |
self.op.hvparams, self.op.beparams, |
|
6085 |
self.op.startup_paused) |
|
6083 |
result = \ |
|
6084 |
self.rpc.call_instance_start(node_current, |
|
6085 |
(instance, self.op.hvparams, |
|
6086 |
self.op.beparams), |
|
6087 |
self.op.startup_paused) |
|
6086 | 6088 |
msg = result.fail_msg |
6087 | 6089 |
if msg: |
6088 | 6090 |
_ShutdownInstanceDisks(self, instance) |
... | ... | |
6172 | 6174 |
self.LogInfo("Instance %s was already stopped, starting now", |
6173 | 6175 |
instance.name) |
6174 | 6176 |
_StartInstanceDisks(self, instance, ignore_secondaries) |
6175 |
result = self.rpc.call_instance_start(node_current, instance,
|
|
6176 |
None, None, False)
|
|
6177 |
result = self.rpc.call_instance_start(node_current, |
|
6178 |
(instance, None, None), False)
|
|
6177 | 6179 |
msg = result.fail_msg |
6178 | 6180 |
if msg: |
6179 | 6181 |
_ShutdownInstanceDisks(self, instance) |
... | ... | |
6334 | 6336 |
try: |
6335 | 6337 |
feedback_fn("Running the instance OS create scripts...") |
6336 | 6338 |
# FIXME: pass debug option from opcode to backend |
6337 |
result = self.rpc.call_instance_os_add(inst.primary_node, inst, True,
|
|
6338 |
self.op.debug_level,
|
|
6339 |
osparams=self.os_inst)
|
|
6339 |
result = self.rpc.call_instance_os_add(inst.primary_node, |
|
6340 |
(inst, self.os_inst), True,
|
|
6341 |
self.op.debug_level)
|
|
6340 | 6342 |
result.Raise("Could not install OS for instance %s on node %s" % |
6341 | 6343 |
(inst.name, inst.primary_node)) |
6342 | 6344 |
finally: |
... | ... | |
7037 | 7039 |
_ShutdownInstanceDisks(self, instance) |
7038 | 7040 |
raise errors.OpExecError("Can't activate the instance's disks") |
7039 | 7041 |
|
7040 |
result = self.rpc.call_instance_start(target_node, instance,
|
|
7041 |
None, None, False)
|
|
7042 |
result = self.rpc.call_instance_start(target_node, |
|
7043 |
(instance, None, None), False)
|
|
7042 | 7044 |
msg = result.fail_msg |
7043 | 7045 |
if msg: |
7044 | 7046 |
_ShutdownInstanceDisks(self, instance) |
... | ... | |
7701 | 7703 |
|
7702 | 7704 |
self.feedback_fn("* starting the instance on the target node %s" % |
7703 | 7705 |
target_node) |
7704 |
result = self.rpc.call_instance_start(target_node, instance, None, None,
|
|
7706 |
result = self.rpc.call_instance_start(target_node, (instance, None, None),
|
|
7705 | 7707 |
False) |
7706 | 7708 |
msg = result.fail_msg |
7707 | 7709 |
if msg: |
... | ... | |
9175 | 9177 |
feedback_fn("* running the instance OS create scripts...") |
9176 | 9178 |
# FIXME: pass debug option from opcode to backend |
9177 | 9179 |
os_add_result = \ |
9178 |
self.rpc.call_instance_os_add(pnode_name, iobj, False,
|
|
9180 |
self.rpc.call_instance_os_add(pnode_name, (iobj, None), False,
|
|
9179 | 9181 |
self.op.debug_level) |
9180 | 9182 |
if pause_sync: |
9181 | 9183 |
feedback_fn("* resuming disk sync") |
... | ... | |
9255 | 9257 |
self.cfg.Update(iobj, feedback_fn) |
9256 | 9258 |
logging.info("Starting instance %s on node %s", instance, pnode_name) |
9257 | 9259 |
feedback_fn("* starting instance...") |
9258 |
result = self.rpc.call_instance_start(pnode_name, iobj,
|
|
9259 |
None, None, False)
|
|
9260 |
result = self.rpc.call_instance_start(pnode_name, (iobj, None, None),
|
|
9261 |
False) |
|
9260 | 9262 |
result.Raise("Could not start instance") |
9261 | 9263 |
|
9262 | 9264 |
return list(iobj.all_nodes) |
... | ... | |
11901 | 11903 |
not self.op.remove_instance): |
11902 | 11904 |
assert not activate_disks |
11903 | 11905 |
feedback_fn("Starting instance %s" % instance.name) |
11904 |
result = self.rpc.call_instance_start(src_node, instance,
|
|
11905 |
None, None, False)
|
|
11906 |
result = self.rpc.call_instance_start(src_node, |
|
11907 |
(instance, None, None), False)
|
|
11906 | 11908 |
msg = result.fail_msg |
11907 | 11909 |
if msg: |
11908 | 11910 |
feedback_fn("Failed to start instance: %s" % msg) |
Also available in: Unified diff