Uploaded image for project: 'VCL'
  1. VCL
  2. VCL-671

VMware may delete VM assigned to another reservation when reclaiming disk space on the host

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.3.1
    • 2.3.2
    • vcld (backend)
    • None
    • Only affects hosts where the vmpath is tight on disk space.

    Description

      There is a logic bug in VMware.pm::reclaim_vmhost_disk_space. It retrieves the other VMs currently loaded on the host and checks if the VM is assigned to another reservation. If so, the VM should not be deleted. If not assigned to any other reservations, the other VM may be a candidate for deletion if space needs to be reclaimed on the host in order to load the VM for the current reservation.

      A hash reference is returned to reclaim_vmhost_disk_space by utils.pm::get_request_by_computerid. The return value is checked:
      my $computer_requests = get_request_by_computerid($check_computer_id);
      if (!keys(%$computer_requests)) {

      1. Not deletable
        }
        else {
      2. Deletable
        }

      This logic is backwards.

      Attachments

        Activity

          People

            arkurth Andrew Kurth
            arkurth Andrew Kurth
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: