Uploaded image for project: 'CloudStack'
  1. CloudStack
  2. CLOUDSTACK-6945

Null pointer exception when starting a VM that had its template deleted

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Duplicate
    • 4.3.0
    • 4.5.0, 4.4.3, 4.3.2
    • Management Server
    • Security Level: Public (Anyone can view this level - this is the default.)
    • None
    • Hosts are Debian 7.4.0 with Xen hypervisor e Xen Cloud Platform packages installed and properly configured.

    Description

      It seems that you have a bug in CS 4.3.0(and probably previous versions?) when starting a machine that was created from a template that has been deleted.

      There will happen a null pointer exception in "com.cloud.vm.VirtualMachineManagerImpl.orchestrateStart":
      “858 - if (volTemplateId != null && volTemplateId.longValue() != template.getId())”

      The object, “template” is going to be null, because in:

      “811 - VirtualMachineTemplate template = _entityMgr.findById(VirtualMachineTemplate.class, vm.getTemplateId());”

      The findById, will add a where clause, looking for template that have the column removed that is null, therefore It will return a null object.

      Attachments

        Issue Links

          Activity

            People

              bhaisaab Rohit Yadav
              rafaelweingartner Rafael Weingärtner
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: