Next VM id doesn't mean there will be disk available
pietrushnic opened this issue · 3 comments
pietrushnic commented
I'm not sure about this assumption, but it looks like vm disk name is generated automatically without checking if it is available:
Error creating machine: Error in driver during machine creation: status code was '500' and error is
500 lvcreate 'pve/vm-100-disk-1' error: Logical Volume "vm-100-disk-1" already exists in volume group "pve"
notifying bugsnag: [Error creating machine: Error in driver during machine creation: status code was '500' and error is
500 lvcreate 'pve/vm-100-disk-1' error: Logical Volume "vm-100-disk-1" already exists in volume group "pve"]
++ docker-machine env new-drv-test
Error checking TLS connection: Error checking and/or regenerating the certs: There was an error validating certificates for host "": dial tcp: missing address
You can attempt to regenerate them using 'docker-machine regenerate-certs [name]'.
Be advised that this will trigger a Docker daemon restart which might stop running containers.
lnxbil commented
Yes, I also encountered this if the previous run failed somehow.
The question is how to react:
- abort (as of now, but maybe with a nicer error message)
- remove the disk in case of an error while creating (only applies to errors directly resulting from running the driver, not from having a disk coincidentally)
- remove the disk and create a new one
I really don't know. Safest approach is to abort and let the human decide if it's save to remove it?
pietrushnic commented
@lnxbil I'm not proxmox expert, can't we use other disk or increase vmid to generate next free?