Closed comet528 closed 2 years ago
Just hit a similar issue as well and had to revert back to 4.79.0
Here is my trace
Error: rpc error: code = Unavailable desc = transport is closing panic: runtime error: invalid memory address or nil pointer dereference 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: [signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x331f659] 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: goroutine 80 [running]: 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/service/core.(CoreRouteTableResourceCrud).SetData(0xc0018b8a20) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_resource.go:350 +0x339 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/tfresource.CreateResource({0x5990ab0, 0xc002854300}, {0x59855f0, 0xc0018b8a20}) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/tfresource/crud_helpers.go:254 +0x35f 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/service/core.createDefaultRouteTable(0xc002854300, {0x5149420, 0xc0030c84f8}) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_default_resource.go:36 +0xe5 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(Resource).create(0xc0018b89f0, {0x5983948, 0xc002862b40}, 0x2, {0x5149420, 0xc0030c84f8}) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:318 +0x178 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(Resource).Apply(0xc001563ce0, {0x5983948, 0xc002862b40}, 0xc001d72310, 0xc002a96500, {0x5149420, 0xc0030c84f8}) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:456 +0x871 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(GRPCProviderServer).ApplyResourceChange(0xc0005aa228, {0x5983948, 0xc002862b40}, 0xc00285e2d0) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/grpc_provider.go:955 +0x9aa 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-go/tfprotov5/server.(server).ApplyResourceChange(0xc000047e40, {0x59839f0, 0xc002a9acf0}, 0x41) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/server/server.go:332 +0x6c 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0x4e93d00, 0xc000047e40}, {0x59839f0, 0xc002a9acf0}, 0xc002bb2420, 0x0) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:380 +0x170 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc.(Server).processUnaryRPC(0xc0005b4700, {0x59b0e70, 0xc00028e900}, 0xc00324a000, 0xc0018b8900, 0x8496420, 0x0) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc@v1.32.0/server.go:1194 +0xc8f 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc.(Server).handleStream(0xc0005b4700, {0x59b0e70, 0xc00028e900}, 0xc00324a000, 0x0) 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc@v1.32.0/server.go:1517 +0xa2a 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc.(Server).serveStreams.func1.2() 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc@v1.32.0/server.go:859 +0x98 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: created by google.golang.org/grpc.(Server).serveStreams.func1 2022-06-15T16:51:53.471Z [DEBUG] plugin.terraform-provider-oci_v4.80.0: google.golang.org/grpc@v1.32.0/server.go:857 +0x294 2022/06/15 16:51:53 [DEBUG] oci_core_default_route_table.llw-public-rt[0]: apply errored, but we're indicating that via the Error pointer rather than returning it: rpc error: code = Unavailable desc = transport is closing 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalMaybeTainted 2022/06/15 16:51:53 [TRACE] EvalMaybeTainted: oci_core_default_route_table.llw-public-rt[0] encountered an error during creation, so it is now marked as tainted 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalWriteState 2022/06/15 16:51:53 [TRACE] EvalWriteState: removing state object for oci_core_default_route_table.llw-public-rt[0] 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalApplyProvisioners 2022/06/15 16:51:53 [TRACE] EvalApplyProvisioners: oci_core_default_route_table.llw-public-rt[0] has no state, so skipping provisioners 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalMaybeTainted 2022/06/15 16:51:53 [TRACE] EvalMaybeTainted: oci_core_default_route_table.llw-public-rt[0] encountered an error during creation, so it is now marked as tainted 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalWriteState 2022-06-15T16:51:53.473Z [DEBUG] plugin: plugin process exited: path=.terraform/plugins/registry.terraform.io/hashicorp/oci/4.80.0/linux_amd64/terraform-provider-oci_v4.80.0 pid=965 error="exit status 2" 2022/06/15 16:51:53 [TRACE] EvalWriteState: removing state object for oci_core_default_route_table.llw-public-rt[0] 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalIf 2022-06-15T16:51:53.473Z [WARN] plugin.stdio: received EOF, stopping recv loop: err="rpc error: code = Unavailable desc = transport is closing" 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalIf 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalWriteDiff 2022/06/15 16:51:53 [TRACE] eval: terraform.EvalApplyPost 2022/06/15 16:51:53 [ERROR] eval: terraform.EvalApplyPost, err: rpc error: code = Unavailable desc = transport is closing 2022/06/15 16:51:53 [ERROR] eval: terraform.EvalSequence, err: rpc error: code = Unavailable desc = transport is closing 2022/06/15 16:51:53 [TRACE] [walkApply] Exiting eval tree: oci_core_default_route_table.llw-public-rt[0] 2022/06/1516:51:53 [TRACE] vertex "oci_core_default_route_table.llw-public-rt[0]" visit complete 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "oci_core_subnet.public-subnet-llw[0]" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "local.public_subnet_id (expand)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "oci_core_instance.llw-hol[0]" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "output.remote_desktop (expand)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "output.instances (expand)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "time_sleep.wait" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "provider[\"registry.terraform.io/hashicorp/oci\"] (close)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "meta.count-boundary (EachMode fixup)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "provider[\"registry.terraform.io/hashicorp/time\"] (close)" errored, so skipping 2022/06/15 16:51:53 [TRACE] dag/walk: upstream of "root" errored, so skipping 2022/06/15 16:51:53 [TRACE] statemgr.Filesystem: no original state snapshot to back up 2022/06/15 16:51:53 [TRACE] statemgr.Filesystem: state has changed since last snapshot, so incrementing serial to 11 2022/06/15 16:51:53 [TRACE] statemgr.Filesystem: writing snapshot at terraform.tfstate 2022/06/15 16:51:53 [TRACE] statemgr.Filesystem: removing lock metadata file .terraform.tfstate.lock.info 2022/06/15 16:51:53 [TRACE] statemgr.Filesystem: unlocking terraform.tfstate using fcntl flock 2022-06-15T16:51:53.477Z [DEBUG] plugin: plugin exited 2022-06-15T16:51:53.478Z [WARN] plugin.stdio: received EOF, stopping recv loop: err="rpc error: code = Unavailable desc = transport is closing" 2022-06-15T16:51:53.478Z [DEBUG] plugin: plugin process exited: path=.terraform/plugins/registry.terraform.io/hashicorp/time/0.6.0/linux_amd64/terraform-provider-time_v0.6.0_x5 pid=974 2022-06-15T16:51:53.478Z [DEBUG] plugin: plugin exited !!!!!!!!!!!!!!!!!!!!!!!!!!! TERRAFORM CRASH !!!!!!!!!!!!!!!!!!!!!!!!!!!!
Similar issue when trying to destroy components created with Terraform a few days ago as well as when I tried to run a create. Using the OCI Stacks web interfaced with a zip file with terraform files in it.
oci_core_route_table.obicoRT: Refreshing state... [id=ocid1.routetable.oc1.iad.aaaaaaaaodnikc4phqq27v7p6t7l4pcqq]
oci_core_network_security_group_security_rule.obico_network_security_group_security_rule_3334: Refreshing state... [id=5F2B]
Error: Plugin did not respond
with oci_core_network_security_group_security_rule.obico_network_security_group_security_rule_3334,
on network-security-group.tf line 8, in resource "oci_core_network_security_group_security_rule" "obico_network_security_group_security_rule_3334"
8: resource "oci_core_network_security_group_security_rule" "obico_network_security_group_security_rule_3334" {
The plugin encountered an error, and failed to respond to the
plugin.(*GRPCProvider).ReadResource call. The plugin logs may contain more
details.
Error: Plugin did not respond
with oci_core_route_table.obicoRT,
on network.tf line 13, in resource "oci_core_route_table" "obicoRT"
13: resource "oci_core_route_table" "obicoRT" {
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-oci_v4.80.0 plugin:
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x331f659]
goroutine 193 [running]:
github.com/terraform-providers/terraform-provider-oci/internal/service/core.(*CoreRouteTableResourceCrud).SetData(0xc001d16660)
github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_resource.go:350 +0x339
github.com/terraform-providers/terraform-provider-oci/internal/tfresource.ReadResource({0x58a39f0, 0xc001d16660})
github.com/terraform-providers/terraform-provider-oci/internal/tfresource/crud_helpers.go:271 +0x124
github.com/terraform-providers/terraform-provider-oci/internal/service/core.readCoreRouteTable(0xc0019e1100, {0x5149420, 0xc00245e4e0})
github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_resource.go:130 +0xd5
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).read(0x51718bc, {0x5983948, 0xc001c8ee40}, 0x24, {0x5149420, 0xc00245e4e0})
github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:335 +0x178
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).RefreshWithoutUpgrade(0xc001521260, {0x5983948, 0xc001c8ee40}, 0xc001c900e0, {0x5149420, 0xc00245e4e0})
github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:624 +0x35b
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ReadResource(0xc000434300, {0x5983948, 0xc001c8ee40}, 0xc001c8ee80)
github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/grpc_provider.go:575 +0x4bd
github.com/hashicorp/terraform-plugin-go/tfprotov5/server.(*server).ReadResource(0xc0004002c0, {0x59839f0, 0xc001cb16b0}, 0xc001c677a0)
github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/server/server.go:298 +0x1fb
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ReadResource_Handler({0x4e93d00, 0xc0004002c0}, {0x59839f0, 0xc001cb16b0}, 0xc001c67740, 0x0)
github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:344 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0xc00042cfc0, {0x59b0e70, 0xc000658000}, 0xc0000d1400, 0xc001892bd0, 0x84963f0, 0x0)
google.golang.org/grpc@v1.32.0/server.go:1194 +0xc8f
google.golang.org/grpc.(*Server).handleStream(0xc00042cfc0, {0x59b0e70, 0xc000658000}, 0xc0000d1400, 0x0)
google.golang.org/grpc@v1.32.0/server.go:1517 +0xa2a
google.golang.org/grpc.(*Server).serveStreams.func1.2()
google.golang.org/grpc@v1.32.0/server.go:859 +0x98
created by google.golang.org/grpc.(*Server).serveStreams.func1
google.golang.org/grpc@v1.32.0/server.go:857 +0x294
Error: The terraform-provider-oci_v4.80.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.
Fix has been merged in v4.80.1 https://github.com/oracle/terraform-provider-oci/releases/tag/v4.80.1 . Please use the latest version and try again. LEt us know if the issue still persists.
Thanks!
closing this issue now
Community Note
Terraform Version and Provider Version
Terraform v1.2.2 on linux_amd64
Affected Resource(s)
oci_core_route_table
Terraform Configuration Files
Debug Output
Panic Output
[WARN] Resource discovery finished with errors listed below:
INFO 2022/06/15 15:34:36.459379 Error discovering
oci_core_route_table
resources for export_OpenDataVCN: [ERROR] terraform import command failed for resource 'oci_core_route_table.export_OpenDataRouteTableViaNAT' at id 'ocid1.routetable.oc1.........': exit status 1Error: 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-oci_v4.80.0 plugin:
panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x331f659]
goroutine 29 [running]: github.com/terraform-providers/terraform-provider-oci/internal/service/core.(CoreRouteTableResourceCrud).SetData(0xc001d90ff0) github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_resource.go:350 +0x339 github.com/terraform-providers/terraform-provider-oci/internal/tfresource.ReadResource({0x58a39f0, 0xc001d90ff0}) github.com/terraform-providers/terraform-provider-oci/internal/tfresource/crud_helpers.go:271 +0x124 github.com/terraform-providers/terraform-provider-oci/internal/service/core.readCoreRouteTable(0xc001cffb80, {0x5149420, 0xc000144660}) github.com/terraform-providers/terraform-provider-oci/internal/service/core/core_route_table_resource.go:130 +0xd5 github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(Resource).read(0x51718bc, {0x5983948, 0xc00020d500}, 0x24, {0x5149420, 0xc000144660}) github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:335 +0x178 github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(Resource).RefreshWithoutUpgrade(0xc001615260, {0x5983948, 0xc00020d500}, 0xc002ccb650, {0x5149420, 0xc000144660}) github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/resource.go:624 +0x35b github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(GRPCProviderServer).ReadResource(0xc00000c498, {0x5983948, 0xc00020d500}, 0xc00020d540) github.com/hashicorp/terraform-plugin-sdk/v2@v2.7.0/helper/schema/grpc_provider.go:575 +0x4bd github.com/hashicorp/terraform-plugin-go/tfprotov5/server.(server).ReadResource(0xc0004c22a0, {0x59839f0, 0xc001d90120}, 0xc002d42480) github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/server/server.go:298 +0x1fb github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ReadResource_Handler({0x4e93d00, 0xc0004c22a0}, {0x59839f0, 0xc001d90120}, 0xc002d42420, 0x0) github.com/hashicorp/terraform-plugin-go@v0.3.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:344 +0x170 google.golang.org/grpc.(Server).processUnaryRPC(0xc00014e8c0, {0x59b0e70, 0xc001a4a000}, 0xc003356200, 0xc0019b5170, 0x84963f0, 0x0) google.golang.org/grpc@v1.32.0/server.go:1194 +0xc8f google.golang.org/grpc.(Server).handleStream(0xc00014e8c0, {0x59b0e70, 0xc001a4a000}, 0xc003356200, 0x0) google.golang.org/grpc@v1.32.0/server.go:1517 +0xa2a google.golang.org/grpc.(Server).serveStreams.func1.2() google.golang.org/grpc@v1.32.0/server.go:859 +0x98 created by google.golang.org/grpc.(*Server).serveStreams.func1 google.golang.org/grpc@v1.32.0/server.go:857 +0x294
Error: The terraform-provider-oci_v4.80.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.
Any references to this resource have been replaced with hard coded values in generated configurations
Expected Behavior
Actual Behavior
Steps to Reproduce
terraform apply
Important Factoids
References