We are getting RPC error while destroying the Azure resources from terraform script. Resources creating
- Resource Group
- Virtual Machines with Subnets
- AKS clusters
- Application Gateway
Please find the below screenshot for reference!
I have been trying to destroy resources through as they were created from terraform.
CodePudding user response:
To solve this rpc error: code = Unavailable desc = transport is closing these type errors will need self-contained reproduction cases.
Terraform CLI should drop a crash.log file in trace logs when a Terraform Provider crash unexpectedly. Mostly these are caused because of the timeout errors. Please try below steps
az login --use-device-codeterraform validate/terraform validate -var-file <.tfvar filename>terraform plan / terraform plan -var-file <.tfvar filename>****terraform apply/terraform apply -var-file <.tfvar filename>terraform destroy
NOTE: -var-file <tfvarfile> is not mandatory. Ignore step 4 if we are running only destroy process.

