Revision 10937a16 tools/move-instance
b/tools/move-instance | ||
---|---|---|
526 | 526 |
odisk[constants.IDISK_SPINDLES] = spindles |
527 | 527 |
disks.append(odisk) |
528 | 528 |
|
529 |
nics = [{ |
|
530 |
constants.INIC_IP: ip, |
|
531 |
constants.INIC_MAC: mac, |
|
532 |
constants.INIC_MODE: mode, |
|
533 |
constants.INIC_LINK: link, |
|
534 |
constants.INIC_VLAN: vlan, |
|
535 |
constants.INIC_NETWORK: network, |
|
536 |
constants.INIC_NAME: nic_name |
|
537 |
} for nic_name, _, ip, mac, mode, link, vlan, network, _ |
|
538 |
in instance["nics"]] |
|
529 |
try: |
|
530 |
nics = [{ |
|
531 |
constants.INIC_IP: ip, |
|
532 |
constants.INIC_MAC: mac, |
|
533 |
constants.INIC_MODE: mode, |
|
534 |
constants.INIC_LINK: link, |
|
535 |
constants.INIC_VLAN: vlan, |
|
536 |
constants.INIC_NETWORK: network, |
|
537 |
constants.INIC_NAME: nic_name |
|
538 |
} for nic_name, _, ip, mac, mode, link, vlan, network, _ |
|
539 |
in instance["nics"]] |
|
540 |
except ValueError: |
|
541 |
raise Error("Received NIC information does not match expected format; " |
|
542 |
"Do the versions of this tool and the source cluster match?") |
|
539 | 543 |
|
540 | 544 |
if len(override_nics) > len(nics): |
541 | 545 |
raise Error("Can not create new NICs") |
Also available in: Unified diff