Skip to content

CLOUDSTACK-9641 In KVM SSVM and CPVM may use the old cmdline data, if… - #2121

Merged
karuturi merged 1 commit into
apache:masterfrom
bvbharatk:CLOUDSTACK-9641
May 23, 2017
Merged

CLOUDSTACK-9641 In KVM SSVM and CPVM may use the old cmdline data, if…#2121
karuturi merged 1 commit into
apache:masterfrom
bvbharatk:CLOUDSTACK-9641

Conversation

@bvbharatk

Copy link
Copy Markdown
Contributor

If we fail to fetch the new cmdline, we do not fail ssvm start. we end up using the old cmdline. So to fix this we are moving the oldcmdline to backup and if we do not find the new one, we fail and restore the old cmdline back.

@cloudmonger

Copy link
Copy Markdown

ACS CI BVT Run

Sumarry:
Build Number 716
Hypervisor xenserver
NetworkType Advanced
Passed=112
Failed=0
Skipped=12

Link to logs Folder (search by build_no): https://www.dropbox.com/sh/r2si930m8xxzavs/AAAzNrnoF1fC3auFrvsKo_8-a?dl=0

Failed tests:

Skipped tests:
test_vm_nic_adapter_vmxnet3
test_01_verify_libvirt
test_02_verify_libvirt_after_restart
test_03_verify_libvirt_attach_disk
test_04_verify_guest_lspci
test_05_change_vm_ostype_restart
test_06_verify_guest_lspci_again
test_static_role_account_acls
test_11_ss_nfs_version_on_ssvm
test_nested_virtualization_vmware
test_3d_gpu_support
test_deploy_vgpu_enabled_vm

Passed test suits:
test_deploy_vm_with_userdata.py
test_affinity_groups_projects.py
test_portable_publicip.py
test_vm_snapshots.py
test_over_provisioning.py
test_global_settings.py
test_scale_vm.py
test_service_offerings.py
test_routers_iptables_default_policy.py
test_loadbalance.py
test_routers.py
test_reset_vm_on_reboot.py
test_deploy_vms_with_varied_deploymentplanners.py
test_network.py
test_router_dns.py
test_non_contigiousvlan.py
test_login.py
test_deploy_vm_iso.py
test_list_ids_parameter.py
test_public_ip_range.py
test_multipleips_per_nic.py
test_metrics_api.py
test_regions.py
test_affinity_groups.py
test_network_acl.py
test_pvlan.py
test_volumes.py
test_nic.py
test_deploy_vm_root_resize.py
test_resource_detail.py
test_secondary_storage.py
test_vm_life_cycle.py
test_routers_network_ops.py
test_disk_offerings.py

}
}

File pemFile=new File("/root/.ssh/id_rsa.cloud");

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

libvirtComputingResource.SSHPRVKEYPATH can be used instead

NicVO nic = _nicsDao.getControlNicForVM(vm.getId());
return nic.getIPv4Address();
}
else if(vm.getType()== VirtualMachine.Type.DomainRouter) return vm.getPrivateIpAddress();

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

except If coding convention ... code LGTM

@bvbharatk

Copy link
Copy Markdown
Contributor Author

test_ssvm.py was also run by CI pasting the results xml file here.
test_ssvm.txt


File pemFile=new File(LibvirtComputingResource.SSHPRVKEYPATH);
try {
if(vmName.contains("s-") || vmName.contains("v-")){

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using startsWith() is better here.

} catch (final LibvirtException e) {
s_logger.debug("unable to stop VM:"+vmName+" due to"+e.getMessage());
try{
if(vmName.contains("s-") || vmName.contains("v-"))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

startsWith() here

@bvbharatk

Copy link
Copy Markdown
Contributor Author

Made the suggested changes.

… we fail to fetch the new cmdline in the first pass.
@sureshanaparti

Copy link
Copy Markdown
Contributor

Code LGTM

@karuturi karuturi added this to the 4.10.0.0 milestone May 19, 2017
@karuturi
karuturi merged commit e25a444 into apache:master May 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants