mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
CLOUDSTACK-7190: Fix Hyper-V issue when attempting SSH to System VMs
This commit is contained in:
parent
d4cebbdc88
commit
57ee142ded
@ -843,7 +843,7 @@ class TestRVRInternals(cloudstackTestCase):
|
||||
self.debug(master_router.linklocalip)
|
||||
|
||||
# Check eth2 port for master router
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -879,7 +879,7 @@ class TestRVRInternals(cloudstackTestCase):
|
||||
)
|
||||
|
||||
# Check eth2 port for backup router
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
|
||||
@ -208,7 +208,7 @@ class TestVRServiceFailureAlerting(cloudstackTestCase):
|
||||
|
||||
alertSubject = "Monitoring Service on VR " + router.name
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
|
||||
@ -179,7 +179,7 @@ class TestDeployVmWithUserData(cloudstackTestCase):
|
||||
host.passwd="password"
|
||||
cmd="cat /var/www/html/userdata/"+deployVmResponse.ipaddress+"/user-data"
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
|
||||
try:
|
||||
result = get_process_status(
|
||||
|
||||
@ -131,8 +131,8 @@ class TestPersistentNetworks(cloudstackTestCase):
|
||||
|
||||
hypervisor = str(get_hypervisor_type(self.api_client))
|
||||
|
||||
if hypervisor.lower() == 'vmware':
|
||||
#SSH is done via management server for Vmware
|
||||
if hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
#SSH is done via management server for Vmware and Hyper-V
|
||||
sourceip = self.api_client.connection.mgtSvr
|
||||
else:
|
||||
#For others, we will have to get the ipaddress of host connected to vm
|
||||
@ -1410,8 +1410,8 @@ class TestRestartPersistentNetwork(cloudstackTestCase):
|
||||
|
||||
hypervisor = str(get_hypervisor_type(self.api_client))
|
||||
|
||||
if hypervisor.lower() == 'vmware':
|
||||
#SSH is done via management server for Vmware
|
||||
if hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
#SSH is done via management server for Vmware and Hyper-V
|
||||
sourceip = self.api_client.connection.mgtSvr
|
||||
else:
|
||||
#For others, we will have to get the ipaddress of host connected to vm
|
||||
|
||||
@ -148,7 +148,7 @@ class TestRouterServices(cloudstackTestCase):
|
||||
"Check list router response for router state"
|
||||
)
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -227,7 +227,7 @@ class TestRouterServices(cloudstackTestCase):
|
||||
"Check list router response for router state"
|
||||
)
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -258,7 +258,7 @@ class TestRouterServices(cloudstackTestCase):
|
||||
"Check dnsmasq service is running or not"
|
||||
)
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -437,7 +437,7 @@ class TestRouterServices(cloudstackTestCase):
|
||||
)
|
||||
host = hosts[0]
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
res = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
|
||||
@ -319,8 +319,8 @@ class TestSSVMs(cloudstackTestCase):
|
||||
|
||||
self.debug("Running SSVM check script")
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
#SSH into SSVMs is done via management server for Vmware
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
#SSH into SSVMs is done via management server for Vmware and Hyper-V
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -359,8 +359,8 @@ class TestSSVMs(cloudstackTestCase):
|
||||
)
|
||||
|
||||
#Check status of cloud service
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
#SSH into SSVMs is done via management server for Vmware
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
#SSH into SSVMs is done via management server for Vmware and Hyper-V
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
@ -443,8 +443,8 @@ class TestSSVMs(cloudstackTestCase):
|
||||
|
||||
self.debug("Checking cloud process status")
|
||||
|
||||
if self.hypervisor.lower() == 'vmware':
|
||||
#SSH into SSVMs is done via management server for vmware
|
||||
if self.hypervisor.lower() in ('vmware', 'hyperv'):
|
||||
#SSH into SSVMs is done via management server for Vmware and Hyper-V
|
||||
result = get_process_status(
|
||||
self.apiclient.connection.mgtSvr,
|
||||
22,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user