Skip to content
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

1.35 version crash, AKS SP problem #4519

Closed
tshafeev opened this issue Oct 4, 2019 · 6 comments · Fixed by #4697
Closed

1.35 version crash, AKS SP problem #4519

tshafeev opened this issue Oct 4, 2019 · 6 comments · Fixed by #4697

Comments

@tshafeev
Copy link

tshafeev commented Oct 4, 2019

When upgraded azurerm provider from version 1.33.1 to 1.35, terraform plan crashed with error

panic: interface conversion: interface {} is nil, not map[string]interface {}
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: goroutine 197 [running]:
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: github.com/terraform-providers/terraform-provider-azurerm/azurerm.flattenAzureRmKubernetesClusterServicePrincipalProfile(0xc000024b90, 0xc000954ee0, 0x19, 0x3280aa0, 0xc0000291a0)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-providers/terraform-provider-azurerm/azurerm/resource_arm_kubernetes_cluster.go:1593 +0x370
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: github.com/terraform-providers/terraform-provider-azurerm/azurerm.resourceArmKubernetesClusterRead(0xc000954ee0, 0x321a320, 0xc0000d7680, 0xc000954ee0, 0x0)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-providers/terraform-provider-azurerm/azurerm/resource_arm_kubernetes_cluster.go:902 +0x163c
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*Resource).Refresh(0xc0007e6180, 0xc00015ff90, 0x321a320, 0xc0000d7680, 0xc000746ad8, 0x3f97601, 0xc000768bf8)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema/resource.go:511 +0x16f
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*Provider).Refresh(0xc000020100, 0xc00015ff40, 0xc00015ff90, 0xc000c4e090, 0xc000a64540, 0x18)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema/provider.go:328 +0x17f
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/plugin.(*ResourceProviderServer).Refresh(0xc00049b880, 0xc0012fe980, 0xc0012fea50, 0x0, 0x0)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/teamcity-agent/work/5d79fe75d4460a2f/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/plugin/resource_provider.go:552 +0x4e
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: reflect.Value.call(0xc000134a20, 0xc000140698, 0x13, 0x389ecc5, 0x4, 0xc000768f18, 0x3, 0x3, 0xc00014d900, 
0xc000be3778, ...)
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/goenv/versions/1.12.6/src/reflect/value.go:447 +0x461
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: reflect.Value.Call(0xc000134a20, 0xc000140698, 0x13, 0xc000be3718, 0x3, 0x3, 0xc00049f4c0, 0x0, 0x0)       
2019-10-04T18:53:53.730+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/goenv/versions/1.12.6/src/reflect/value.go:308 +0xa4
2019-10-04T18:53:53.731+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: net/rpc.(*service).call(0xc00014d0c0, 0xc00015ea50, 0xc000143080, 0xc000143090, 0xc000020600, 0xc000c3e9c0, 0x32492a0, 0xc0012fe980, 0x16, 0x32492e0, ...)
2019-10-04T18:53:53.731+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/goenv/versions/1.12.6/src/net/rpc/server.go:384 +0x14e
2019-10-04T18:53:53.731+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4: created by net/rpc.(*Server).ServeCodec
2019-10-04T18:53:53.731+0300 [DEBUG] plugin.terraform-provider-azurerm_v1.35.0_x4:      /opt/goenv/versions/1.12.6/src/net/rpc/server.go:481 +0x42b
2019/10/04 18:53:53 [ERROR] root: eval: *terraform.EvalRefresh, err: azurerm_kubernetes_cluster.arm_aks_aks: unexpected EOF
2019/10/04 18:53:53 [ERROR] root: eval: *terraform.EvalSequence, err: azurerm_kubernetes_cluster.arm_aks_aks: unexpected EOF
2019/10/04 18:53:53 [TRACE] [walkRefresh] Exiting eval tree: azurerm_kubernetes_cluster.arm_aks_aks
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "provider.kubernetes"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "kubernetes_namespace.prom"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "azurerm_key_vault.k8s_kv"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "kubernetes_cluster_role_binding.tiller-rbac"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "kubernetes_secret.kv_secret"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "azurerm_key_vault_secret.kv_key"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "azurerm_key_vault_secret.kv_ca"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "kubernetes_cluster_role_binding.dashboard-rbac"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "azurerm_key_vault_secret.kv_cert"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "provider.kubernetes (close)"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "provider.azurerm (close)"
2019/10/04 18:53:53 [TRACE] dag/walk: upstream errored, not walking "root"
2019/10/04 18:53:53 [DEBUG] plugin: waiting for all plugin processes to complete...
2019-10-04T18:53:53.732+0300 [WARN ] plugin: error closing client during Kill: err="connection is shut down"
2019-10-04T18:53:53.732+0300 [DEBUG] plugin.terraform-provider-azuread_v0.6.0_x4: 2019/10/04 18:53:53 [ERR] plugin: stream copy 'stderr' error: stream closed
2019-10-04T18:53:53.733+0300 [DEBUG] plugin.terraform-provider-azuread_v0.6.0_x4: 2019/10/04 18:53:53 [ERR] plugin: plugin server: accept unix /tmp/plugin300909146: use of closed network connection
2019-10-04T18:53:53.734+0300 [DEBUG] plugin.terraform-provider-kubernetes_v1.9.0_x4: 2019/10/04 18:53:53 [ERR] plugin: plugin server: accept unix /tmp/plugin919031240: use of closed network 
connection
2019-10-04T18:53:53.736+0300 [DEBUG] plugin: plugin process exited: path=/mnt/d/some_path/tf-aks-rbac/.terraform/plugins/linux_amd64/terraform-provider-azurerm_v1.35.0_x4
2019-10-04T18:53:53.736+0300 [DEBUG] plugin: plugin process exited: path=/mnt/d/some_path/tf-aks-rbac/.terraform/plugins/linux_amd64/terraform-provider-azuread_v0.6.0_x4
[crash.log](https://github.com/terraform-providers/terraform-provider-azurerm/files/3691310/crash.log)

2019-10-04T18:53:53.737+0300 [DEBUG] plugin: plugin process exited: path=/some_path/.terraform/plugins/linux_amd64/terraform-provider-kubernetes_v1.9.0_x4```
@tshafeev
Copy link
Author

tshafeev commented Oct 8, 2019

So it's kind of related to #4469, so after all investigations and probes, i upgraded terraform to 0.12 version and azurerm 1.33.1 apply updated for 0.12v configs/states. Then i upgrade azurerm to 1.35 version and everything became okish ;) . So not sure if it should be closed or not.

@pawel7318
Copy link

provider "azurerm" {
  # whilst the `version` attribute is optional, we recommend pinning to a given version of the Provider
  version = "=1.34.0"
}

@brennerm
Copy link
Contributor

Encountering the same problem with azurerm provider version 1.35.0 and Terraform 0.11.14.

@Veraticus
Copy link

Also encountered this; reverting to version 1.34.0 fixes it.

@ghost
Copy link

ghost commented Oct 29, 2019

This has been released in version 1.36.0 of the provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. As an example:

provider "azurerm" {
    version = "~> 1.36.0"
}
# ... other configuration ...

@ghost
Copy link

ghost commented Nov 23, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Nov 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.