Increase capacity of disk of thick provisioned eager zeroed ends up with disk type thick provisioned lazy zeroed
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 2.3k
- Forks
- 763
- PR merge metrics
- No merged PRs in 30d
Description
Hi all,
I am trying to extend a disk with reconfigure_vm of type thick provisioned eager zeroed but afterwards the disk type is always changed to thick provisioned lazy zeroed. Please see code snipped below:
spec = vim.vm.ConfigSpec()
disk_devices = get_disk_devices(vm)
vdevice_spec = vim.vm.device.VirtualDeviceSpec()
disk_spec = disk_devices[0]
disk_spec.capacityInKB = 100 * 1024 * 1024
vdevice_spec.device = disk_spec
vdevice_spec.operation = vim.vm.device.VirtualDeviceSpec.Operation.edit
spec.deviceChange = [vdevice_spec]
self.reconfigure_vm(vm, spec)
Remark: The get_disk_device gets all disk devices from the vm_object. Only the first one in the list gets extended.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the reconfigure_vm call and the vim.vm.device.VirtualDeviceSpec edit shown in the issue, then inspect how get_disk_devices supplies the disk object. Reproduce the capacity increase for a thick provisioned eager-zeroed disk and determine why the resulting type becomes lazy-zeroed. Done means the disk capacity increases without changing its provisioning type.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100