Bug 2295395 - HTTPError: 401 Client Error: Unauthorized for url :3100/api/dashboards/db [NEEDINFO]
Summary: HTTPError: 401 Client Error: Unauthorized for url :3100/api/dashboards/db
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat Storage
Component: Ceph-Ansible
Version: 5.3
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ---
: 5.3z8
Assignee: Teoman ONAY
QA Contact: Sayalee
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-07-03 12:15 UTC by Kenny Tordeurs
Modified: 2025-02-13 19:23 UTC (History)
15 users (show)

Fixed In Version: ceph-ansible-6.0.28.17-1.el8cp
Doc Type: Bug Fix
Doc Text:
.Mismatched dashboard `id` causes Grafana dashboard update failures Previously, during an update, if an `id` was specified but did not match an existing dashboard, the `Error EINVAL: Traceback` error was emitted and the Grafana update would fail. With this fix, the update completes successfully.
Clone Of:
Environment:
Last Closed: 2025-02-13 19:22:55 UTC
Embargoed:
ktordeur: needinfo-
rpollack: needinfo? (tonay)
rpollack: needinfo? (tonay)


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker OSP-32436 0 None None None 2024-07-03 12:17:02 UTC
Red Hat Issue Tracker RHCEPH-10277 0 None None None 2024-11-22 18:47:36 UTC
Red Hat Knowledge Base (Solution) 6965628 0 None None None 2024-08-08 12:02:39 UTC
Red Hat Product Errata RHBA-2025:1478 0 None None None 2025-02-13 19:22:59 UTC

Description Kenny Tordeurs 2024-07-03 12:15:41 UTC
Description of problem:
HTTPError: 401 Client Error: Unauthorized for url :3100/api/dashboards/db

Version-Release number of selected component (if applicable):
16.2 > 17.1

How reproducible:
100%

Steps to Reproduce:
1. # openstack overcloud external-upgrade run --skip-tags "ceph_health,opendev-validation, ceph_ansible_remote_tmp" --stack openstack --tags ceph,facts --yes
2.
3.

Actual results:
"TASK [ceph-dashboard : inject grafana dashboard layouts] ***********************",

"fatal: [openstack001 -> openstack001]: FAILED! => {\"changed\": false, \"cmd\": [\"podman\", \"exec\", \"ceph-mon-openstack001\", \"ceph\", \"--cluster\", \"ceph\", \"dashboard\", \"grafana\", \"dashboards\", \"update\"], \"delta\": \"0:00:01.088045\", \"end\": \"2024-06-14 02:31:40.765994\", \"msg\": \"non-zero return code\", \"rc\": 22, \"start\": \"2024-06-14 02:31:39.677949\", \"stderr\": \"Error EINVAL: Traceback (most recent call last):\\n  File \\\"/usr/share/ceph/mgr/mgr_module.py\\\", line 1446, in _handle_command\\n    return self.handle_command(inbuf, cmd)\\n  File \\\"/usr/share/ceph/mgr/dashboard/module.py\\\", line 529, in handle_command\\n    push_local_dashboards()\\n  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 136, in push_local_dashboards\\n    retry()\\n  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 93, in __call__\\n    result = self.func(*self.args, **self.kwargs)\\n  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 131, in push\\n    grafana.push_dashboard(body)\\n  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 58, in push_dashboard\\n    response.raise_for_status()\\n  File \\\"/lib/python3.6/site-packages/requests/models.py\\\", line 940, in raise_for_status\\n    raise HTTPError(http_error_msg, response=self)\\nrequests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: http://192.168.3.5:3100/api/dashboards/db\", \"stderr_lines\": [\"Error EINVAL: Traceback (most recent call last):\", \"  File \\\"/usr/share/ceph/mgr/mgr_module.py\\\", line 1446, in _handle_command\", \"    return self.handle_command(inbuf, cmd)\", \"  File \\\"/usr/share/ceph/mgr/dashboard/module.py\\\", line 529, in handle_command\", \"    push_local_dashboards()\", \"  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 136, in push_local_dashboards\", \"    retry()\", \"  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 93, in __call__\", \"    result = self.func(*self.args, **self.kwargs)\", \"  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 131, in push\", \"    grafana.push_dashboard(body)\", \"  File \\\"/usr/share/ceph/mgr/dashboard/grafana.py\\\", line 58, in push_dashboard\", \"    response.raise_for_status()\", \"  File \\\"/lib/python3.6/site-packages/requests/models.py\\\", line 940, in raise_for_status\", \"    raise HTTPError(http_error_msg, response=self)\", \"requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: http://192.168.3.5:3100/api/dashboards/db\"], \"stdout\": \"\", \"stdout_lines\": []}",

Expected results:
no errors

Additional info:
Add the ignore_errors: true flag in the task of the playbook /usr/share/ceph-ansible/roles/ceph-dashboard/tasks/configure_grafana_layouts.yml to workaround this

Comment 3 Kenny Tordeurs 2024-08-08 12:02:59 UTC
This is the KCS that explains the same issue: https://access.redhat.com/solutions/6965628

Comment 27 errata-xmlrpc 2025-02-13 19:22:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Red Hat Ceph Storage 5.3 security and bug fix updates), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2025:1478


Note You need to log in before you can comment on or make changes to this bug.