F5Networks / terraform-provider-bigip

Terraform resources that can configure F5 BIG-IP products
https://registry.terraform.io/providers/F5Networks/bigip/latest/docs
Mozilla Public License 2.0
103 stars 119 forks source link

Terraform error while deploying to LTM VE #943

Closed kamalmachareka closed 7 months ago

kamalmachareka commented 7 months ago

Environment

Summary

I started to get the following errors when trying to deploy a change to virtual f5s

│ Error: Plugin did not respond │ │ The plugin encountered an error, and failed to respond to the plugin.(*GRPCProvider).ReadResource call. The │ plugin logs may contain more details. ╵

Stack trace from the terraform-provider-bigip_v1.11.0 plugin:

panic: runtime error: index out of range [1] with length 0

goroutine 69 [running]: github.com/F5Networks/terraform-provider-bigip/bigip.resourceBigipNetSelfIPRead(0xc000212e00, 0x10d2760, 0xc0006fc0e0, 0xc000212e00, 0x0) github.com/F5Networks/terraform-provider-bigip/bigip/resource_bigip_net_selfip.go:102 +0x5cf github.com/hashicorp/terraform-plugin-sdk/helper/schema.(Resource).RefreshWithoutUpgrade(0xc000203200, 0xc00065eb90, 0x10d2760, 0xc0006fc0e0, 0xc00000e2a8, 0x0, 0x0) github.com/hashicorp/terraform-plugin-sdk@v1.1.0/helper/schema/resource.go:455 +0x12e github.com/hashicorp/terraform-plugin-sdk/internal/helper/plugin.(GRPCProviderServer).ReadResource(0xc000186ba0, 0x127fd50, 0xc000117d70, 0xc00065ea50, 0xc000186ba0, 0xc000117d70, 0xc0005f5a50) github.com/hashicorp/terraform-plugin-sdk@v1.1.0/internal/helper/plugin/grpc_provider.go:525 +0x3dd github.com/hashicorp/terraform-plugin-sdk/internal/tfplugin5._Provider_ReadResource_Handler(0x108e480, 0xc000186ba0, 0x127fd50, 0xc000117d70, 0xc000082f60, 0x0, 0x127fd50, 0xc000117d70, 0xc000326090, 0x8b) github.com/hashicorp/terraform-plugin-sdk@v1.1.0/internal/tfplugin5/tfplugin5.pb.go:3153 +0x214 google.golang.org/grpc.(Server).processUnaryRPC(0xc0001d0000, 0x1288678, 0xc00018af00, 0xc000316f00, 0xc000554600, 0x183e8d0, 0x0, 0x0, 0x0) google.golang.org/grpc@v1.23.0/server.go:995 +0x482 google.golang.org/grpc.(Server).handleStream(0xc0001d0000, 0x1288678, 0xc00018af00, 0xc000316f00, 0x0) google.golang.org/grpc@v1.23.0/server.go:1275 +0xd2c google.golang.org/grpc.(Server).serveStreams.func1.1(0xc00012a1a0, 0xc0001d0000, 0x1288678, 0xc00018af00, 0xc000316f00) google.golang.org/grpc@v1.23.0/server.go:710 +0xab created by google.golang.org/grpc.(Server).serveStreams.func1 google.golang.org/grpc@v1.23.0/server.go:708 +0xa5

Error: The terraform-provider-bigip_v1.11.0 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.

Steps To Reproduce

Steps to reproduce the behavior:

Working on VLAN and SelfIP Resource provisioning

Expected Behavior

This is a new build. Previous deployments went fine and I got few VLANs and self-IPs provisioned. I had to change the VLAN and IP of the management interface, which I've done in the past and Terraform continued to work. This time however, it is erroring out. It may or may not be related.

Actual Behavior

I get the error and logs above

kamalmachareka commented 7 months ago

I remove all files, including state, and deployed an empty config to clean everything up, and then re-deployed the original configuration. This time it worked!