Skip to content

Remove restriction, in VMWare, to resize only SCSI disks#5650

Merged
yadvr merged 6 commits intoapache:mainfrom
scclouds:remove-vmware-restriction-resize-only-scsi-disks
Jan 8, 2022
Merged

Remove restriction, in VMWare, to resize only SCSI disks#5650
yadvr merged 6 commits intoapache:mainfrom
scclouds:remove-vmware-restriction-resize-only-scsi-disks

Conversation

@SadiJr
Copy link
Copy Markdown
Contributor

@SadiJr SadiJr commented Nov 1, 2021

Description

In VMWare, there are different types of SCSI controllers, such as BusLogic Parallel, LSI Logic Parallel, LSI Logic SAS, etc. All of these sub-types support the disk resize operation, the only exception is the IDE controller. However, in ACS, there is a logical restriction to allow only resizing of volumes of the specific SCSI type; thus, not allowing resizing of the SCSI sub-types. This PR corrects this behavior blocking the resize of volumes which uses IDE controller only.
More information can be found at:

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

How Has This Been Tested?

I tested it in a local lab:

  1. I created a VM with lsisas1068 SAS controller.
  2. I tried to resize the volume and got this error message: "Found unsupported root disk controller: lsisas1068".
  3. With the changes from this PR, I was able to resize the volume correctly.

…are supports resize of subtypes of SCSI, like LSILOGIC, LSILOGIC SAS, etc
@SadiJr SadiJr changed the title Remove restriction, in VMWare, to resize only SCSI disks, because VMW… Remove restriction, in VMWare, to resize only SCSI disks Nov 1, 2021
@shwstppr
Copy link
Copy Markdown
Contributor

shwstppr commented Nov 2, 2021

@blueorangutan package

throw new Exception(errorMsg);
}

if (vdisk.second() != null && !vdisk.second().toLowerCase().startsWith("scsi")) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think we have to keep a counter check for IDE controller here, instead of just removing the SCSI check.
I see we are checking it in UserVMManagerImpl but there are other places where resize volume is initiated. So it is better to keep a check in resource layer. Can you please add that.

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.

@SadiJr Alternatively, you can check for specific controller types from com.cloud.hypervisor.vmware.mo.ScsiDiskControllerType (or) com.cloud.hypervisor.vmware.mo.DiskControllerType

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@harikrishna-patnala The IDE controller check is done on the top line (

if (vdisk.second() != null && vdisk.second().contains("ide")) {
), so I see no reason to redo it here. @sureshanaparti is an option, however, if in the future new types of SCSI controllers are added, this code would have to be revised to accommodate the changes. Rather than checking for allowed controllers, it is much more practical to check for disallowed controllers.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✖️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 1657

@SadiJr
Copy link
Copy Markdown
Contributor Author

SadiJr commented Nov 3, 2021

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@SadiJr a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 1672

@shwstppr
Copy link
Copy Markdown
Contributor

shwstppr commented Nov 3, 2021

@blueorangutan test centos7 vmware-67u3

@blueorangutan
Copy link
Copy Markdown

@shwstppr a Trillian-Jenkins test job (centos7 mgmt + vmware-67u3) has been kicked to run smoke tests

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Nov 18, 2021

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✖️ suse15. SL-JID 1726

@DaanHoogland
Copy link
Copy Markdown
Contributor

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@DaanHoogland a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 1913

@sureshanaparti
Copy link
Copy Markdown
Contributor

@blueorangutan test centos7 vmware-67u3

@yadvr
Copy link
Copy Markdown
Member

yadvr commented Dec 30, 2021

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rohityadavcloud a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✖️ suse15. SL-JID 2042

Copy link
Copy Markdown
Member

@GabrielBrascher GabrielBrascher left a comment

Choose a reason for hiding this comment

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

Code LGTM

@yadvr yadvr changed the base branch from main to 4.16 December 30, 2021 17:36
@yadvr yadvr changed the base branch from 4.16 to main December 30, 2021 17:36
@yadvr
Copy link
Copy Markdown
Member

yadvr commented Dec 30, 2021

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@rohityadavcloud a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 2049

@DaanHoogland
Copy link
Copy Markdown
Contributor

@blueorangutan test centos7 vmware-67

@blueorangutan
Copy link
Copy Markdown

@DaanHoogland unsupported parameters provided. Supported mgmt server os are: centos7, centos6, alma8, ubuntu18, suse15, ubuntu20, rocky8, centos8. Supported hypervisors are: kvm-centos6, kvm-centos7, kvm-centos8, kvm-rocky8, kvm-alma8, kvm-ubuntu18, kvm-ubuntu20, kvm-suse15, vmware-55u3, vmware-60u2, vmware-65u2, vmware-67u3, vmware-70u1, xenserver-65sp1, xenserver-71, xenserver-74, xcpng74, xcpng76, xcpng80, xcpng81, xcpng82

@DaanHoogland
Copy link
Copy Markdown
Contributor

@blueorangutan test centos7 vmware-67u3

@blueorangutan
Copy link
Copy Markdown

@DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + vmware-67u3) has been kicked to run smoke tests

Copy link
Copy Markdown
Member

@harikrishna-patnala harikrishna-patnala left a comment

Choose a reason for hiding this comment

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

Code LGTM

@blueorangutan
Copy link
Copy Markdown

Trillian test result (tid-2759)
Environment: vmware-67u3 (x2), Advanced Networking with Mgmt server 7
Total time taken: 34692 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5650-t2759-vmware-67u3.zip
Smoke tests completed. 91 look OK, 0 have errors
Only failed tests results shown below:

Test Result Time (s) Test File

@yadvr yadvr merged commit 5d7ea30 into apache:main Jan 8, 2022
@yadvr yadvr added this to the 4.17.0.0 milestone Jan 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants