Revision c42be2c0 lib/hypervisor/hv_kvm.py
b/lib/hypervisor/hv_kvm.py | ||
---|---|---|
2452 | 2452 |
return result |
2453 | 2453 |
|
2454 | 2454 |
@classmethod |
2455 |
def GetInstanceConsole(cls, instance, primary_node, hvparams, beparams): |
|
2455 |
def GetInstanceConsole(cls, instance, primary_node, node_group, |
|
2456 |
hvparams, beparams): |
|
2456 | 2457 |
"""Return a command for connecting to the console of an instance. |
2457 | 2458 |
|
2458 | 2459 |
""" |
... | ... | |
2462 | 2463 |
utils.ShellQuote(cls._InstanceMonitor(instance.name)), |
2463 | 2464 |
"STDIO,%s" % cls._SocatUnixConsoleParams(), |
2464 | 2465 |
"UNIX-CONNECT:%s" % cls._InstanceSerial(instance.name)] |
2466 |
ndparams = node_group.FillND(primary_node) |
|
2465 | 2467 |
return objects.InstanceConsole(instance=instance.name, |
2466 | 2468 |
kind=constants.CONS_SSH, |
2467 | 2469 |
host=primary_node.name, |
2470 |
port=ndparams.get(constants.ND_SSH_PORT), |
|
2468 | 2471 |
user=constants.SSH_CONSOLE_USER, |
2469 | 2472 |
command=cmd) |
2470 | 2473 |
|
Also available in: Unified diff