Proxmox is converting my disk when it should be importing it

SpiderUnderUrBed

New Member
Feb 17, 2025
5
0
1
Code:
file = "local:0,import-from=/home/spiderunderurbed/hdd/vms/vm-1/nixos.qcow2";
size = "20G"; # This should match or be larger than the size of your current disk image
format = "qcow2";  # Specify that the format is qcow2
This is translated into a vm configuration file for proxmox, does anyone know why, despite specifying a disk file and to import from it, and including the format, that it attempts to copy it to /var/. I tried making the format and the filetype the same, didnt fix it. This is likely a proxmox issue as the tool i use is simply passing in the file attribute directly, and proxmox is interpreting it in a weird way

Error:

https://pastebin.com/RXmftQLD

Here is my configuration (dont focus on the nix part, you can still understand what does what):

[EDIT]
I heard there was this option called target-datastore with qm importdisk
you use when running the qm command, is there something equivalent to this over the api or file

https://pastebin.com/cGC9cLgN

and incase anyone knows nixmoxer, so i can fix the code in the project i am using, does anyone know how to use proxmoxer or proxmox's api to force a created vm to use a disk directly, rather than importing, here is some proxmoxer code:
https://pastebin.com/CQAyX16p
Refer to the create_vm bit
that is, if nothing else relating to my configuration would fix this, then the solution might be in the api
 
Last edited:
Hi!

This is unrelated to Proxmox VE directly, but from a quick glance it seems that nixmoxer has a own option for import-form at [0]. Apart from that, the task log you added shows that there is no space left on the device:

Code:
qemu-img: error while writing at byte 19797114880: No space left on device
qemu-img: Failed to flush the L2 table cache: No space left on device
qemu-img: Failed to flush the refcount block cache: No space left on device

despite specifying a disk file and to import from it, and including the format, that it attempts to copy it to /var/.
This is by design, since importing does mean that PVE copies the VM volume to a PVE-managed storage, which is not the original path where it is imported from.

[0] https://github.com/SaumonNet/proxmo...d86bf1/modules/declarative-vms/options.nix#L6