terraform-provider-proxmox
terraform-provider-proxmox copied to clipboard
Running `make example` sporadically fails with `scsi0: invalid format` error
Describe the bug A clear and concise description of what the bug is.
To Reproduce Steps to reproduce the behavior:
- Run
make example - If you're unlucky you may see:
tls_private_key.proxmox_virtual_environment_certificate: Creating...
tls_private_key.example: Creating...
proxmox_virtual_environment_cluster_alias.example: Creating...
proxmox_virtual_environment_role.example: Creating...
proxmox_virtual_environment_time.example: Creating...
proxmox_virtual_environment_cluster_ipset.example: Creating...
proxmox_virtual_environment_dns.example: Creating...
proxmox_virtual_environment_file.ubuntu_cloud_image: Creating...
proxmox_virtual_environment_file.ubuntu_container_template: Creating...
proxmox_virtual_environment_hosts.example: Creating...
tls_private_key.proxmox_virtual_environment_certificate: Creation complete after 0s [id=85aa38b34c0aea0f69cee4b56f0d042315b3a97b]
proxmox_virtual_environment_pool.example: Creating...
tls_private_key.example: Creation complete after 0s [id=c281cae3a7bef72c6f7e50eaa93ac65636596fa6]
tls_self_signed_cert.proxmox_virtual_environment_certificate: Creating...
tls_self_signed_cert.proxmox_virtual_environment_certificate: Creation complete after 0s [id=304105590674019447920336097746891321877]
local_sensitive_file.example_ssh_public_key: Creating...
local_sensitive_file.example_ssh_public_key: Creation complete after 0s [id=6448807b6ed81c643253b8da16b51f941ee3b938]
proxmox_virtual_environment_cluster_alias.example: Creation complete after 0s [id=example]
proxmox_virtual_environment_dns.example: Creation complete after 0s [id=pve_dns]
local_sensitive_file.example_ssh_private_key: Creating...
local_sensitive_file.example_ssh_private_key: Creation complete after 0s [id=2f8defdba7d09af60146c5d7b3c50b80b310b3b7]
proxmox_virtual_environment_file.cloud_config: Creating...
proxmox_virtual_environment_certificate.example: Creating...
data.proxmox_virtual_environment_cluster_alias.example: Reading...
proxmox_virtual_environment_role.example: Creation complete after 0s [id=terraform-provider-proxmox-example]
data.proxmox_virtual_environment_cluster_aliases.example: Reading...
proxmox_virtual_environment_pool.example: Creation complete after 0s [id=terraform-provider-proxmox-example]
data.proxmox_virtual_environment_cluster_alias.example: Read complete after 0s [id=example]
data.proxmox_virtual_environment_cluster_aliases.example: Read complete after 0s [id=aliases]
proxmox_virtual_environment_hosts.example: Creation complete after 0s [id=pve_hosts]
data.proxmox_virtual_environment_roles.example: Reading...
proxmox_virtual_environment_cluster_ipset.example: Creation complete after 0s [id=local_network]
proxmox_virtual_environment_time.example: Creation complete after 0s [id=pve_time]
data.proxmox_virtual_environment_role.example: Reading...
data.proxmox_virtual_environment_pools.example: Reading...
data.proxmox_virtual_environment_roles.example: Read complete after 0s [id=roles]
data.proxmox_virtual_environment_pool.example: Reading...
data.proxmox_virtual_environment_pools.example: Read complete after 1s [id=pools]
data.proxmox_virtual_environment_role.example: Read complete after 1s [id=terraform-provider-proxmox-example]
data.proxmox_virtual_environment_pool.example: Read complete after 1s [id=terraform-provider-proxmox-example]
proxmox_virtual_environment_file.cloud_config: Creation complete after 1s [id=local:snippets/terraform-provider-proxmox-example-cloud-config.yaml]
proxmox_virtual_environment_certificate.example: Creation complete after 2s [id=pve_certificate]
proxmox_virtual_environment_file.ubuntu_cloud_image: Still creating... [10s elapsed]
proxmox_virtual_environment_file.ubuntu_container_template: Still creating... [10s elapsed]
proxmox_virtual_environment_file.ubuntu_cloud_image: Still creating... [20s elapsed]
proxmox_virtual_environment_file.ubuntu_container_template: Still creating... [20s elapsed]
proxmox_virtual_environment_file.ubuntu_container_template: Creation complete after 26s [id=local:vztmpl/ubuntu-18.04-standard_18.04.1-1_amd64.tar.gz]
proxmox_virtual_environment_container.example_template: Creating...
proxmox_virtual_environment_file.ubuntu_cloud_image: Still creating... [30s elapsed]
proxmox_virtual_environment_file.ubuntu_cloud_image: Creation complete after 35s [id=local:iso/bionic-server-cloudimg-amd64.img]
proxmox_virtual_environment_vm.example_template: Creating...
proxmox_virtual_environment_container.example_template: Still creating... [10s elapsed]
proxmox_virtual_environment_container.example_template: Creation complete after 10s [id=2042]
proxmox_virtual_environment_container.example: Creating...
proxmox_virtual_environment_container.example: Still creating... [10s elapsed]
proxmox_virtual_environment_container.example: Still creating... [20s elapsed]
proxmox_virtual_environment_container.example: Creation complete after 28s [id=2043]
╷
│ Error: Image resized.
│ VM is locked (create)
│ 400 Parameter verification failed.
│ scsi0: invalid format - format error
│ scsi0.file: invalid format - unable to parse volume ID 'local-lvm:'
│
│
│ qm set <vmid> [OPTIONS]
│
│
│ with proxmox_virtual_environment_vm.example_template,
│ on resource_virtual_environment_vm.tf line 1, in resource "proxmox_virtual_environment_vm" "example_template":
│ 1: resource "proxmox_virtual_environment_vm" "example_template" {
│
╵
make: *** [example-apply] Error 1
- Run
make example-destroy && make exampleagain -- no errors 🤷🏻
Expected behavior
make example should not randomly throw "invalid format" error
Screenshots N/A
Additional context Symptoms suggest there is a race condition somewhere in the provider's code. Happens only for VM, not LXC.
more chances to have this error on a "cold" PVE -- e.g. a test proxmox instance that was running idle.
Marking this issue as stale due to inactivity in the past 180 days. This helps us focus on the active issues. If this issue is reproducible with the latest version of the provider, please comment. If this issue receives no comments in the next 30 days it will automatically be closed. If this issue was automatically closed and you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thank you!