[GH-ISSUE #66] Error: json: cannot unmarshal string into Go struct field VirtualMachineConfig.cpulimit of type int #13

Closed
opened 2026-03-03 15:29:30 +03:00 by kerem · 0 comments
Owner

Originally created by @ricardoalcantara on GitHub (Aug 2, 2023).
Original GitHub issue: https://github.com/luthermonson/go-proxmox/issues/66

Shouldn't cpulimit be float32? I have set mine to 0.4 to give my VM a fraction of my CPU Core? It works on proxmox but the go-proxmox API cannot unmarshal it.

[Edit]
In the documentation https://pve.proxmox.com/wiki/Qemu/KVM_Virtual_Machines it says

...
...Resource Limits...
With the cpulimit (“Host CPU Time”) option you can limit how much CPU time the whole VM can use on the host. It is a floating point value representing CPU time in percent, so 1.0 is equal to 100%, 2.5 to 250% and so on.
...

Originally created by @ricardoalcantara on GitHub (Aug 2, 2023). Original GitHub issue: https://github.com/luthermonson/go-proxmox/issues/66 Shouldn't cpulimit be float32? I have set mine to 0.4 to give my VM a fraction of my CPU Core? It works on proxmox but the go-proxmox API cannot unmarshal it. [Edit] In the documentation https://pve.proxmox.com/wiki/Qemu/KVM_Virtual_Machines it says ... ...Resource Limits... With the cpulimit (“Host CPU Time”) option you can limit how much CPU time the whole VM can use on the host. It is a floating point value representing CPU time in percent, so 1.0 is equal to 100%, 2.5 to 250% and so on. ...
kerem closed this issue 2026-03-03 15:29:36 +03:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/go-proxmox#13
No description provided.