Skip to content

Max vcpu limit of 255 is too low #5345

@peng6662001

Description

@peng6662001

Describe the bug
The VM on Ampere Altra returns Error parsing config: Error parsing --cpus: unable to convert 256 for boot when I use --cpus boot=256,max=256.
I found the root cuase is that the size of boot_vcpus is too small,please help to fix it.

vmm/src/config.rs
CpusConfig
  fn parse
    let boot_vcpus: u8 = parser
            .convert("boot")
            .map_err(Error::ParseCpus)?
            .unwrap_or(DEFAULT_VCPUS);

VM configuration

target/aarch64-unknown-linux-gnu/debug/cloud-hypervisor --cpus boot=256,max=256 --memory size=4G --kernel /home/dom/cloud-hypervisor/bin/Image --cmdline 'root=/dev/vda1 rw systemd.journald.forward_to_console=1' --disk path=/root/osdisk.img --disk path=/root/cloudinit --net tap=,mac=12:34:56:78:90:00,ip=172.19.0.1,mask=255.255.255.0,num_queues=2,queue_size=256

Guest OS version details:
cloud-hypervisor v30.0-93-gd3ac6a85

Host OS version details:
Distributor ID: Ubuntu
Description: Ubuntu 22.04.1 LTS
Release: 22.04
Codename: jammy

Metadata

Metadata

Assignees

No one assigned

    Labels

    AArch64Affects AArch64 only

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions