Comment 0 for bug 1978489

Revision history for this message
Artom Lifshitz (notartom) wrote :

Description
===========

Using the libvirt driver and a host OS that uses cgroups v2 (RHEL 9, Ubuntu Jammy), an instance with more than 16 CPUs cannot be booted.

Steps to reproduce
==================

1. Boot an instance with 10 (or more) CPUs on RHEL 9 or Ubuntu Jammy using Nova with the libvirt driver.

Expected result
===============

Instance boots.

Actual result
=============

Instance fails to boot with a 'Value specified in CPUWeight is out of range' error.

Environment
===========

Originially report as a libvirt but in RHEL 9 [1]

Additional information
======================

This is happening because Nova defaults to 1024 * (# of CPUs) for the value of domain/cputune/shares in the libvirt XML. This is then passed directly by libvirt to the cgroups API, but cgroups v2 has a maximum value of 10000. 10000 / 1024 ~= 9.76

[1] https://bugzilla.redhat.com/show_bug.cgi?id=2035518