terraform
install_error
ai_generated
partial
Error: Failed to download module: checksum mismatch for module source from registry.terraform.io/hashicorp/consul/aws
ID: terraform/module-source-checksum-mismatch
75%Fix Rate
85%Confidence
1Evidence
2024-01-10First Seen
Version Compatibility
| Version | Status | Introduced | Deprecated | Notes |
|---|---|---|---|---|
| Terraform v1.6.0 | active | — | — | — |
| Terraform v1.7.0 | active | — | — | — |
| Terraform v1.8.0 | active | — | — | — |
Root Cause
The downloaded module archive's checksum does not match the expected checksum in the Terraform registry, indicating a corrupted download or tampered module.
generic中文
下载的模块存档的校验和与 Terraform 注册表中预期的校验和不匹配,表明下载损坏或模块被篡改。
Official Documentation
https://developer.hashicorp.com/terraform/language/modules/sources#module-checksumsWorkarounds
-
85% success Clean the module cache and re-download: 'rm -rf .terraform/modules && terraform init'.
Clean the module cache and re-download: 'rm -rf .terraform/modules && terraform init'.
-
80% success If the issue persists, specify an exact module version in the source: 'source = "hashicorp/consul/aws" version = "0.11.0"' and run 'terraform init -upgrade'.
If the issue persists, specify an exact module version in the source: 'source = "hashicorp/consul/aws" version = "0.11.0"' and run 'terraform init -upgrade'.
-
70% success Check network connectivity and proxy settings, then use a different mirror: 'terraform init -plugin-dir=/path/to/mirror'.
Check network connectivity and proxy settings, then use a different mirror: 'terraform init -plugin-dir=/path/to/mirror'.
中文步骤
清理模块缓存并重新下载:'rm -rf .terraform/modules && terraform init'。
如果问题持续存在,在源中指定精确模块版本:'source = "hashicorp/consul/aws" version = "0.11.0"' 并运行 'terraform init -upgrade'。
检查网络连接和代理设置,然后使用不同的镜像:'terraform init -plugin-dir=/path/to/mirror'。
Dead Ends
Common approaches that don't work:
-
90% fail
The corrupted download persists in the .terraform/modules cache.
-
80% fail
The lock file will be regenerated with the same mismatch on next init.
-
60% fail
May introduce breaking changes or other errors.