Revision c42be2c0 lib/hypervisor/hv_xen.py
b/lib/hypervisor/hv_xen.py | ||
---|---|---|
772 | 772 |
instance_list = self._GetInstanceList(True, hvparams) |
773 | 773 |
return _GetNodeInfo(result.stdout, instance_list) |
774 | 774 |
|
775 |
def GetInstanceConsole(self, instance, primary_node, hvparams, beparams): |
|
775 |
def GetInstanceConsole(self, instance, primary_node, node_group, |
|
776 |
hvparams, beparams): |
|
776 | 777 |
"""Return a command for connecting to the console of an instance. |
777 | 778 |
|
778 | 779 |
""" |
779 | 780 |
xen_cmd = self._GetCommand(hvparams) |
781 |
ndparams = node_group.FillND(primary_node) |
|
780 | 782 |
return objects.InstanceConsole(instance=instance.name, |
781 | 783 |
kind=constants.CONS_SSH, |
782 | 784 |
host=primary_node.name, |
785 |
port=ndparams.get(constants.ND_SSH_PORT), |
|
783 | 786 |
user=constants.SSH_CONSOLE_USER, |
784 | 787 |
command=[pathutils.XEN_CONSOLE_WRAPPER, |
785 | 788 |
xen_cmd, instance.name]) |
Also available in: Unified diff