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

Provider crashed: managed_zone_id value out of range #15676

Closed
AlxCloudRl opened this issue Aug 30, 2023 · 5 comments
Closed

Provider crashed: managed_zone_id value out of range #15676

AlxCloudRl opened this issue Aug 30, 2023 · 5 comments
Assignees

Comments

@AlxCloudRl
Copy link

Issue: Doing a Terraform plan, I get a crash panic by Google Terraform provider, related to an ID that is too big to parse. This ID is stored in the Terraform state for the google_dns_managed_zone ressource.

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request.
  • Please do not leave +1 or me too comments, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.
  • If an issue is assigned to the modular-magician user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned to hashibot, a community member has claimed the issue already.

Terraform Version

Terraform v1.5.5
on linux_386

  • provider registry.terraform.io/hashicorp/google v4.80.0
  • provider registry.terraform.io/hashicorp/google-beta v4.80.0
  • provider registry.terraform.io/hashicorp/null v3.2.1
  • provider registry.terraform.io/hashicorp/random v3.5.1
  • provider registry.terraform.io/hashicorp/time v0.9.1

Affected Resource(s)

  • google_dns_managed_zone

Terraform Configuration Files

It's not an issue about the config but about a crash due to a ressource ID stored in the state, considered too big by Google terraform provider.

Panic Output

https://gist.github.com/AlxCloudRl/308303af9916a30628846cf93d81e1fe

Steps to Reproduce

terraform plan

Important Factoids

The out of range value (6159704459778898177) is the ID (managed_zone_id) in the state of the created google_dns_managed_zone ressource.

"module": "module.gcp-gke",
      "mode": "managed",
      "type": "google_dns_managed_zone",
      "name": "gitlab",
      "provider": "provider[\"registry.terraform.io/hashicorp/google\"]",
      "instances": [
        {
          "schema_version": 0,
          "attributes": {
            "cloud_logging_config": [
              {
                "enable_logging": false
              }
            ],
            "creation_time": "2023-08-21T08:32:20.169Z",
            "description": xxx",
            "dns_name": "xxx",
            "dnssec_config": [],
            "force_destroy": false,
            "forwarding_config": [],
            "id": "projects/xxx/managedZones/xxxl",
            "labels": {},
            "managed_zone_id": 6159704459778898177,
            "name": "xxx",
            "name_servers": [
              "ns-gcp-private.googledomains.com."
            ],
           ...

Thanks

@AlxCloudRl AlxCloudRl added the bug label Aug 30, 2023
@edwardmedia edwardmedia self-assigned this Aug 30, 2023
@edwardmedia edwardmedia assigned slevenick and unassigned edwardmedia Aug 30, 2023
@slevenick
Copy link
Collaborator

@AlxCloudRl Are you running this on a 32-bit system? We are aware of a problem with the Terraform SDK related to 32-bit systems and integers that can't fit into 32 bits.

Unfortunately we don't have a lot of options to work around this, as it's a restriction at the SDK level

See hashicorp/terraform-plugin-sdk#1236

@AlxCloudRl
Copy link
Author

@slevenick no my system is 64 bits: Debian 5.10.179-5 (2023-08-08) x86_64 GNU/Linux

@slevenick
Copy link
Collaborator

Hm, from your original bug report it looks like the output of terraform -v is:

Terraform v1.5.5
on linux_386

provider registry.terraform.io/hashicorp/google v4.80.0
provider registry.terraform.io/hashicorp/google-beta v4.80.0
provider registry.terraform.io/hashicorp/null v3.2.1
provider registry.terraform.io/hashicorp/random v3.5.1
provider registry.terraform.io/hashicorp/time v0.9.1

I believe linux_386 is a 32-bit system which would explain this issue. Are you getting the same result on the 64-bit x86_64? Can you provide the output of terraform -v on that system?

@AlxCloudRl
Copy link
Author

You got me on the right track! Indeed, my system is x86_64, but by mistake I must have installed the 32 bits Terraform binary. I installed the AMD64 one and the problem got fixed! Thank you!

@github-actions
Copy link

github-actions bot commented Oct 1, 2023

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants