Project

General

Profile

Bug #43224

ceph osd status error

Added by Alexander Kazansky 4 months ago. Updated 3 months ago.

Status:
Duplicate
Priority:
Urgent
Assignee:
-
Category:
-
Target version:
% Done:

0%

Source:
Tags:
low-hanging-fruit
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature:

Description

Hello.

I received error when try execute 'ceph osd status', it happens when cluster have some osd down.

# ceph osd status
Error EINVAL: Traceback (most recent call last):
  File "/usr/share/ceph/mgr/mgr_module.py", line 914, in _handle_command
    return self.handle_command(inbuf, cmd)
  File "/usr/share/ceph/mgr/status/module.py", line 253, in handle_command
    return self.handle_osd_status(cmd)
  File "/usr/share/ceph/mgr/status/module.py", line 237, in handle_osd_status
    mgr_util.format_dimless(self.get_rate("osd", osd_id.__str__(), "osd.op_w") +
  File "/usr/share/ceph/mgr/status/module.py", line 47, in get_rate
    return (data[-1][1] - data[-2][1]) / float(data[-1][0] - data[-2][0])
ZeroDivisionError: float division by zero

if all osd up, command executed normal.

Related issues

Duplicates mgr - Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py Resolved

History

#1 Updated by Brad Hubbard 4 months ago

  • Project changed from Ceph to mgr
  • Category deleted (ceph cli)

#2 Updated by Sage Weil 4 months ago

  • Priority changed from Normal to Urgent

#3 Updated by Neha Ojha 3 months ago

  • Tags set to low-hanging-fruit

#4 Updated by Stephan Müller 3 months ago

This will be fixed with my PR (https://github.com/ceph/ceph/pull/28603) as soon it is merged.

#5 Updated by Sebastian Wagner 3 months ago

Note that https://github.com/ceph/ceph/pull/28603 fixes a copy of this code in the dashboard module. someone would need to adapt the code in the status module, too.

#6 Updated by Nathan Cutler 3 months ago

  • Related to Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py added

#7 Updated by Sage Weil 3 months ago

  • Pull request ID set to 28603

#8 Updated by Nathan Cutler 3 months ago

  • Related to deleted (Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py)

#9 Updated by Nathan Cutler 3 months ago

  • Duplicates Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py added

#10 Updated by Nathan Cutler 3 months ago

  • Status changed from New to Duplicate

#11 Updated by Nathan Cutler 3 months ago

  • Status changed from Duplicate to New
  • Pull request ID deleted (28603)

Sebastian wrote above: "Note that https://github.com/ceph/ceph/pull/28603 fixes a copy of this code in the dashboard module. someone would need to adapt the code in the status module, too."

which I take to mean that this issue is tracking the problem in the status module.

#12 Updated by Nathan Cutler 3 months ago

  • Duplicates deleted (Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py)

#13 Updated by Nathan Cutler 3 months ago

  • Related to Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py added

#14 Updated by Stephan Müller 3 months ago

  • Related to deleted (Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py)

#15 Updated by Stephan Müller 3 months ago

  • Duplicates Feature #40365: mgr: Add get_rates_from_data from the dashboard to the mgr_util.py added

#16 Updated by Sage Weil 3 months ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 28603

#17 Updated by Sage Weil 3 months ago

  • Status changed from Fix Under Review to Duplicate

Also available in: Atom PDF