You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Vote on this issue by adding a 👍 reaction to the original issue initial description to help the maintainers prioritize.
Do not leave "+1" or other comments that do not add relevant information or questions.
If you are interested in working on this issue or have submitted a pull request, please leave a comment.
Terraform
v1.9.8
Terraform Provider
2.10.0
VMware vSphere
VMWare 8.0.2
Description
After deploying Virtual_switches with Terraform, then adding an Uplink manually, and migrating a bunch of VM's to this new Switch from a DistributedSwitch. "Terraform plan" crashes stating that it is a bug. Plz report it.
If you delete the virtualSwitches from the state-file. You can run Terraform plan and you will get "adds" to all the virtual switches you have added.
If you try to import the virtual switches you will get the same error
Error: The terraform-provider-vsphere_v2.10.0_x5.exe plugin crashed!
This is always indicative of a bug within the plugin. It would be immensely
helpful if you could report the crash with the plugin's maintainers so that it
can be fixed. The output above should help diagnose the issue.
Expected Behavior
Expected to get the Switch imported
Actual Behavior
It fails with nothing imported to the state
Steps to Reproduce
Add a Virtual switch, add an uplink and migrate a VM to it. Run a new Terraform Plan
Environment Details
No response
Screenshots
No response
References
No response
The text was updated successfully, but these errors were encountered:
Community Guidelines
Terraform
v1.9.8
Terraform Provider
2.10.0
VMware vSphere
VMWare 8.0.2
Description
After deploying Virtual_switches with Terraform, then adding an Uplink manually, and migrating a bunch of VM's to this new Switch from a DistributedSwitch. "Terraform plan" crashes stating that it is a bug. Plz report it.
If you delete the virtualSwitches from the state-file. You can run Terraform plan and you will get "adds" to all the virtual switches you have added.
If you try to import the virtual switches you will get the same error
Affected Resources or Data Sources
resource/vsphere_host_virtual_switch
Terraform Configuration
resource "vsphere_host_virtual_switch" "vSwitchProd" {
}
Debug Output
vsphere_host_virtual_switch.vSwitchProd["fridhostesxi01"]: Import prepared!
Prepared vsphere_host_virtual_switch for import
vsphere_host_virtual_switch.vSwitchProd["fridhostesxi01"]: Refreshing state... [id=tf-HostVirtualSwitch:host-179482:vSwitchProd]
╷
│ Error: Request cancelled
│
│ The plugin.(*GRPCProvider).ReadResource request was cancelled.
╵
Panic Output
Stack trace from the terraform-provider-vsphere_v2.10.0_x5.exe plugin:
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x10 pc=0xe2c25c]
goroutine 1444 [running]:
github.com/hashicorp/terraform-provider-vsphere/vsphere.flattenLinkDiscoveryProtocolConfig(0xc000b9d280, 0x0)
github.com/hashicorp/terraform-provider-vsphere/vsphere/host_virtual_switch_structure.go:98 +0x1c
github.com/hashicorp/terraform-provider-vsphere/vsphere.flattenHostVirtualSwitchBondBridge(0xc000b9d280, 0xc00088a090)
github.com/hashicorp/terraform-provider-vsphere/vsphere/host_virtual_switch_structure.go:121 +0x185
github.com/hashicorp/terraform-provider-vsphere/vsphere.flattenHostVirtualSwitchSpec(0xc000b9d280, 0xc0004e12f0)
github.com/hashicorp/terraform-provider-vsphere/vsphere/host_virtual_switch_structure.go:172 +0x9f
github.com/hashicorp/terraform-provider-vsphere/vsphere.resourceVSphereHostVirtualSwitchRead(0xc000b9d280, {0x10d78c0?, 0xc00054a000?})
github.com/hashicorp/terraform-provider-vsphere/vsphere/resource_vsphere_host_virtual_switch.go:98 +0x10f
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).read(0x1639a88?, {0x1639a88?, 0xc0007029f0?}, 0xd?, {0x10d78c0?, 0xc00054a000?})
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:811 +0x15f
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).RefreshWithoutUpgrade(0xc000086e00, {0x1639a88, 0xc0007029f0}, 0xc000047110, {0x10d78c0, 0xc00054a000})
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:1117 +0x529
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ReadResource(0xc00025fd70, {0x1639a88?, 0xc000702930?}, 0xc0000b2280)
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/grpc_provider.go:708 +0x6c5
github.com/hashicorp/terraform-plugin-go/tfprotov5/tf5server.(*server).ReadResource(0xc0003b2460, {0x1639a88?, 0xc00077bec0?}, 0xc00020e000)
github.com/hashicorp/[email protected]/tfprotov5/tf5server/server.go:783 +0x309
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ReadResource_Handler({0x13d2760, 0xc0003b2460}, {0x1639a88, 0xc00077bec0}, 0xc000b9c000, 0x0)
github.com/hashicorp/[email protected]/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:482 +0x1a6
google.golang.org/grpc.(*Server).processUnaryRPC(0xc000193000, {0x1639a88, 0xc00077be30}, {0x163ea00, 0xc000214600}, 0xc000786000, 0xc0002af890, 0x2102608, 0x0)
google.golang.org/[email protected]/server.go:1369 +0xdf8
google.golang.org/grpc.(*Server).handleStream(0xc000193000, {0x163ea00, 0xc000214600}, 0xc000786000)
google.golang.org/[email protected]/server.go:1780 +0xe8b
google.golang.org/grpc.(*Server).serveStreams.func2.1()
google.golang.org/[email protected]/server.go:1019 +0x8b
created by google.golang.org/grpc.(*Server).serveStreams.func2 in goroutine 29
google.golang.org/[email protected]/server.go:1030 +0x125
Error: The terraform-provider-vsphere_v2.10.0_x5.exe plugin crashed!
This is always indicative of a bug within the plugin. It would be immensely
helpful if you could report the crash with the plugin's maintainers so that it
can be fixed. The output above should help diagnose the issue.
Expected Behavior
Expected to get the Switch imported
Actual Behavior
It fails with nothing imported to the state
Steps to Reproduce
Add a Virtual switch, add an uplink and migrate a VM to it. Run a new Terraform Plan
Environment Details
No response
Screenshots
No response
References
No response
The text was updated successfully, but these errors were encountered: