-
Notifications
You must be signed in to change notification settings - Fork 454
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deleting larger datastores with vsphere_vmfs_datastore
times out
#2249
Comments
Hello, ianc769! 🖐 Thank you for submitting an issue for this provider. The issue will now enter into the issue lifecycle. If you want to contribute to this project, please review the contributing guidelines and information on submitting pull requests. |
Workaround:
|
Have you tried setting the provider "vsphere" {
user = var.vsphere_user
password = var.vsphere_password
vsphere_server = var.vsphere_server
allow_unverified_ssl = true
api_timeout = 10
} This will override the default timeout. terraform-provider-vsphere/vsphere/provider.go Lines 186 to 195 in 0a41cd6
Ryan Johnson |
Hey @tenthirtyam Does this affect the resource itself? I see that the default is Fully deleting the datastore takes about 1 minute it looks like. I can try the build/destroy again with it doubled to |
Also noticing similar behaviour regardless of destroying a VM when deleting multiple datastores. In our case, we are attempting to destroy 8 datastores and receive a timeout on any that are not deleted within 30 seconds or 1 minute and 5 seconds (we've seen both, however it is now only 30 seconds). Workaround mentioned here is the same as we've found works ourselves, however as we're using pipelines triggered by users unfamiliar with Terraform this wouldn't work as the timeout would cause the pipeline to consider itself failed. Behaviour is noticeable even on relatively small, unused datastores (50-100GB). Changing the API Timeout seems to have no effect on this. Terraform Terraform Provider VMware vSphere |
Is there any news on this? Issue has been around since 2018 - even a workaround to manually set the timeout in the resource block would be greatly appreciated. |
Community Guidelines
Terraform
1.8.5
Terraform Provider
2.8.2
VMware vSphere
8.0.2.00300
Description
Possibly related #417
Deleting vms that have larger disks, In our case 600GBx2, the operation times out since vSphere takes longer than 30s to delete them.
Perhaps having a customizable wait timer would be a good route for this resource, as vSphere seems to be a little iffy on timing.
Affected Resources or Data Sources
resources/vsphere_vmfs_datastore
Possibly this code:
terraform-provider-vsphere/vsphere/resource_vsphere_vmfs_datastore.go
Lines 407 to 415 in 0a41cd6
Terraform Configuration
Debug Output
https://gist.github.com/ianc769/b6fa08135736fa5db09ff49e5c85bd11
Panic Output
No response
Expected Behavior
Full Deletion with no issues.
Actual Behavior
Error Presenting if we hit the 30s mark.
Steps to Reproduce
Add a VM with a few large disks. Then delete them via Terraform.
Environment Details
No response
Screenshots
References
#417
The text was updated successfully, but these errors were encountered: