Minor request on qm --memory setting

Himcules

New Member
Jan 8, 2024
20
0
1
In my attempts to write a shell script to create VMs quickly I've got oneliners working fine i.e.

# qm create 9999 --name vmtest --bios ovmf --efidisk0 data:0,efitype=4m,pre-enrolled-keys=1 --boot "order=net0;scsi0" --cores 1 --sockets 1 --cpu host --memory 2048 --net0 model=virtio,bridge=vmbr0
--scsihw virtio-scsi-single --scsi0 data:30,iothread=1 --tpmstate0 data:0,version=v2.0

Minor request is:
--memory as from the quoted manpage:

"--memory <integer> (16 - N) (default = 512) Amount of RAM for the VM in MiB.
This is the maximum available memory when you use the balloon device."

* Can this be updated/modified so that we can pass a values in other forms?
For other types of values expressed as; GiB, GB,TiB and or TB.
i.e. syntax:
--memory 2048
--memory 2G
 
Hey,

this sounds like a useful thing to have, feel free to open an issue in our Bugtracker.
Please check if someone has already requested this, but from a quick search I only found this and that only targets the webui.

When you have done so, please post a link to the issue here, so others can find it.