Open
Description
Terraform Version
v0.12.5
Terraform Configuration Files
This is the entire config required to reproduce.
provider "aws" {}
Debug Output
This is with terraform validate
, though most commands hit the same error.
2019/07/24 14:59:04 [INFO] Terraform version: 0.12.5
2019/07/24 14:59:04 [INFO] Go runtime version: go1.12.4
2019/07/24 14:59:04 [INFO] CLI args: []string{"/usr/local/bin/terraform", "validate"}
2019/07/24 14:59:04 [DEBUG] Attempting to open CLI config file: /home/thisguy/.terraformrc
2019/07/24 14:59:04 [DEBUG] File doesn't exist, but doesn't need to. Ignoring.
2019/07/24 14:59:04 [INFO] CLI command args: []string{"validate"}
2019/07/24 14:59:04 [DEBUG] checking for provider in "."
2019/07/24 14:59:04 [DEBUG] checking for provider in "/usr/local/bin"
2019/07/24 14:59:04 [DEBUG] checking for provider in ".terraform/plugins/linux_amd64"
2019/07/24 14:59:04 [DEBUG] found provider "terraform-provider-aws_v2.20.0_x4"
2019/07/24 14:59:04 [DEBUG] checking for provider in "/home/thisguy/.terraform.d/plugins"
2019/07/24 14:59:04 [DEBUG] found valid plugin: "aws", "2.20.0", "/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4"
2019/07/24 14:59:04 [DEBUG] checking for provisioner in "."
2019/07/24 14:59:04 [DEBUG] checking for provisioner in "/usr/local/bin"
2019/07/24 14:59:04 [DEBUG] checking for provisioner in ".terraform/plugins/linux_amd64"
2019/07/24 14:59:04 [DEBUG] checking for provisioner in "/home/thisguy/.terraform.d/plugins"
2019/07/24 14:59:04 [TRACE] terraform.NewContext: starting
2019/07/24 14:59:04 [TRACE] terraform.NewContext: resolving provider version selections
2019/07/24 14:59:04 [TRACE] terraform.NewContext: loading provider schemas
2019/07/24 14:59:04 [TRACE] LoadSchemas: retrieving schema for provider type "aws"
2019-07-24T14:59:04.734-0400 [INFO] plugin: configuring client automatic mTLS
2019-07-24T14:59:04.765-0400 [DEBUG] plugin: starting plugin: path=/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4 args=[/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4]
2019-07-24T14:59:04.765-0400 [DEBUG] plugin: plugin started: path=/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4 pid=29439
2019-07-24T14:59:04.765-0400 [DEBUG] plugin: waiting for RPC address: path=/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4
2019-07-24T14:59:04.783-0400 [ERROR] plugin.terraform-provider-aws_v2.20.0_x4: plugin init error: error="listen unix /home/thisguy/code/provtes/thisdirnameisverylongandallitneedstobeistoolonganditwillmakethepr/plugin569537193: bind: invalid argument" timestamp=2019-07-24T14:59:04.782-0400
2019-07-24T14:59:04.785-0400 [DEBUG] plugin: plugin process exited: path=/home/thisguy/code/provtes/.terraform/plugins/linux_amd64/terraform-provider-aws_v2.20.0_x4 pid=29439
2019-07-24T14:59:04.785-0400 [WARN] plugin: plugin failed to exit gracefully
Error: Failed to instantiate provider "aws" to obtain schema: Unrecognized remote plugin message:
This usually means that the plugin is either invalid or simply
needs to be recompiled to support the latest protocol.
Expected Behavior
Success! The configuration is valid.
Actual Behavior
Error: Failed to instantiate provider "aws" to obtain schema: Unrecognized remote plugin message:
This usually means that the plugin is either invalid or simply
needs to be recompiled to support the latest protocol.
Steps to Reproduce
- Have the
TMPDIR
environment variable be 93 characters long, or longer. - Run
terraform init
- Run
terraform (validate|plan|apply)
Additional Context
My build systems sets to TMPDIR
to a build/run specific directory. That's how I hit this.
I have validated the same error occurs for the aws, google, chef, cloudflare, and grafana providers (probably more, but I figured that was enough). So I'm fairly certain this is an issue with the github.com/hashicorp/terraform/plugin
library and not any individual provider.