← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 2023018] Re: scaling governors are optional for some OS platforms

 

Reviewed:  https://review.opendev.org/c/openstack/nova/+/885352
Committed: https://opendev.org/openstack/nova/commit/2c4421568ea62e66257b55c08092de3e0303fb0a
Submitter: "Zuul (22348)"
Branch:    master

commit 2c4421568ea62e66257b55c08092de3e0303fb0a
Author: Sylvain Bauza <sbauza@xxxxxxxxxx>
Date:   Tue Jun 6 11:56:32 2023 +0200

    cpu: make governors to be optional
    
    Change-Id: Ifb7d001cfdb95b1b0aa29f45c0ef71c0673e1760
    Closes-Bug: #2023018


** Changed in: nova
       Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/2023018

Title:
  scaling governors are optional for some OS platforms

Status in OpenStack Compute (nova):
  Fix Released

Bug description:
  Some OS platforms don't use cpufreq, so operators should be able to
  just offline their CPUs.

  For the moment, even if the config option CPU management strategy is
  'cpu_state', we return an exception if so.

  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service Traceback (most recent call last):
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/filesystem.py", line 37, in read_sys
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     with open(os.path.join(SYS, path), mode='r') as data:
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service FileNotFoundError: [Errno 2] No such file or directory: '/sys/devices/system/cpu/cpu1/cpufreq/scaling_governor'
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service 
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service The above exception was the direct cause of the following exception:
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service 
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service Traceback (most recent call last):
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/usr/local/lib/python3.10/dist-packages/oslo_service/service.py", line 806, in run_service
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     service.start()
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/service.py", line 162, in start
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     self.manager.init_host(self.service_ref)
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/compute/manager.py", line 1608, in init_host
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     self.driver.init_host(host=self.host)
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/virt/libvirt/driver.py", line 825, in init_host
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     libvirt_cpu.validate_all_dedicated_cpus()
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/virt/libvirt/cpu/api.py", line 143, in validate_all_dedicated_cpus
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     governors.add(pcpu.governor)
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/virt/libvirt/cpu/api.py", line 63, in governor
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     return core.get_governor(self.ident)
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/virt/libvirt/cpu/core.py", line 69, in get_governor
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     return filesystem.read_sys(
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service   File "/opt/stack/nova/nova/filesystem.py", line 40, in read_sys
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service     raise exception.FileNotFound(file_path=path) from exc
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service nova.exception.FileNotFound: File /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor could not be found.
  Jun 05 14:47:45 sbauza-dev2 nova-compute[75181]: ERROR oslo_service.service 

  Let's just to support the CPU state if so.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/2023018/+subscriptions



References