← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 2120549] Re: [IRONIC][Caracal] - Get Host Uptime is Broken

 

Greetings,

The call your reporting form nova, not Ironic, is in the nova virt
driver to speak with Ironic.

Specifically, the driver looks to collect the "compute node uptime", a
concept which doesn't really exist in the Ironic world because it has no
real parallel meaning or mapping. Because Ironic's nodes are presented
as whole "compute nodes" which can be consumed. The running nova-compute
service, instead of generating one record, translates the nodes across
and proxies calls to Ironic.

As a result, there is not an identifiable uptime which would make sense
for the running nova-compute service in that nova deployment which would
map to the physical nodes being "serviced" by that compute endpoint.

I think there may already be a nova bug on this issue, and at some point
I think we discussed that this error should just be suppressed in their
logging. In any event, I'm going to change the state on this bug to
accurately represent Ironic. If you wish to approach Nova please let us
know. Thanks!


** Changed in: ironic
       Status: In Progress => Won't Fix

-- 
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/2120549

Title:
   [IRONIC][Caracal] - Get Host Uptime is Broken

Status in Ironic:
  Won't Fix
Status in OpenStack Compute (nova):
  In Progress

Bug description:
  ++++++++++++
  ENV Details:
  ++++++++++++

  ```
  root@jj-caracal-online:~# cat /etc/openstack-release
  # Ansible managed

  DISTRIB_ID="OSA"
  DISTRIB_RELEASE="29.2.3.dev1"
  DISTRIB_CODENAME="Caracal"
  DISTRIB_DESCRIPTION="OpenStack-Ansible"
  root@jj-caracal-online:~#
  ```

  ++++++
  Issue:
  ++++++
  > [!NOTE]
  > I am executing the command as admin.

  ```
  Aug 13 10:05:51 jj-caracal-online.ct.lan nova-compute[337506]: 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server [None req-4ff10130-49d7-427e-b5c5-402d39687967 7310ba37996640bf94c0712aafe954fa 4d620e29ef8e4a90a3db8535f540fde3 - - default default] Exception during message handling: NotImplementedError
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server Traceback (most recent call last):
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/oslo_messaging/rpc/server.py", line 165, in _process_incoming
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     res = self.dispatcher.dispatch(message)
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/oslo_messaging/rpc/dispatcher.py", line 309, in dispatch
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     return self._do_dispatch(endpoint, method, ctxt, args)
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/oslo_messaging/rpc/dispatcher.py", line 229, in _do_dispatch
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     result = func(ctxt, **new_args)
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/nova/exception_wrapper.py", line 65, in wrapped
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     with excutils.save_and_reraise_exception():
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/oslo_utils/excutils.py", line 227, in __exit__
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     self.force_reraise()
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/oslo_utils/excutils.py", line 200, in force_reraise
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     raise self.value
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/nova/exception_wrapper.py", line 63, in wrapped
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     return f(self, context, *args, **kw)
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/nova/compute/manager.py", line 6779, in get_host_uptime
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     return self.driver.get_host_uptime()
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server   File "/openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/nova/virt/driver.py", line 1504, in get_host_uptime
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server     raise NotImplementedError()
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server NotImplementedError
                                                                 2025-08-13 10:05:51.041 337506 ERROR oslo_messaging.rpc.server 
  ```

  +++++++++++
  Code Snipp:
  +++++++++++ 

  * The code is not implemented yet.

  ```
  /openstack/venvs/nova-29.2.3.dev1/lib/python3.10/site-packages/nova/virt/driver.py
  ```

  ```
      def get_host_uptime(self):
          """Returns the result of the time since start up of this hypervisor.

          :return: A text which contains the uptime of this host since the
                   last boot.
          :rtype: str
          """
          # TODO(Vek): Need to pass context in for access to auth_token
          raise NotImplementedError()
   ```

  Thanks, 
  cNilesh.

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