Project

General

Profile

Actions

Bug #52002

closed

mgr/dashboard: dashboard 16.2.5 unable to ipv6 wildcard bind

Added by Scott Shambarger over 2 years ago. Updated about 1 year ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
% Done:

100%

Source:
Community (user)
Tags:
backport_processed
Backport:
pacific, octopus
Regression:
No
Severity:
2 - major
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

Description of problem

Commit 157a7b418 (cherry picked as ad964c42a) updated how the service URL was calculated, but appears to have (inadvertently?) changed the bind address as well.

Affected file: src/pybind/mgr/dashboard/module.py around line 110

If server_addr is "::", it replaces it using get_mgr_ip(). However, the modified variable is used for the CherryPy config option 'server.socket_host' which causes the Dashboard to only bind to the individual manager ip (and not the wildcard address as in previous versions, and as documented).

A workaround for ipv4 can be accomplished by setting server_addr to 0.0.0.0, but then the URL is incorrect. There is no longer any way to bind to the ipv6 wildcard...

The fix should be to use the get_mgr_ip for the URL specifically, and leave the server_addr alone.

Additionally, the URL should be fixed to use the manager ip if the server_addr is :: OR 0.0.0.0.

Environment

  • ceph version string: ceph version 16.2.5 (0883bdea7337b95e4b611c768c0279868462204a) pacific (stable)
  • Platform (OS/distro/release): Fedora 34
  • Cluster details (nodes, monitors, OSDs): ...
  • Did it happen on a stable environment or after a migration/upgrade?: cephadm install
  • Browser used (e.g.: Version 86.0.4240.198 (Official Build) (64-bit)): Firefox 90

How reproducible

Steps:

  1. Using multi-homed host with multiple networks (eg 10.0.10.50/24, 192.168.10.50/24)
  2. Install using cephadm with dashboard defaults, with --mon-addrv "[v2:10.0.10.50:3300]"
  3. Attempt to load the dashboard on a network that differs from the public_network, eg https://192.168.10.50:8443

Actual results

Connection fails. Dashboard is bound to a single IP address:
$ ss -lnt | grep 8443
LISTEN 0 5 10.0.10.32:8443 0.0.0.0:*

Expected results

Dashboard should be available on all interfaces:
$ ss -lnt | grep 8443
LISTEN 0 128 0.0.0.0:8443 0.0.0.0:*
LISTEN 0 128 [::]:8443 [::]:*

Additional info

The initial commit also made the same change to the prometheus module

File: src/pybind/mgr/prometheus/module.py around line 1380

It also changed the wildcard address... and there is no workaround as it affects both ":" and "0.0.0.0" server_addr values.


Related issues 2 (0 open2 closed)

Copied to Dashboard - Backport #52802: octopus: mgr/dashboard: dashboard 16.2.5 unable to ipv6 wildcard bindRejectedActions
Copied to Dashboard - Backport #52803: pacific: mgr/dashboard: dashboard 16.2.5 unable to ipv6 wildcard bindResolvedAvan ThakkarActions
Actions

Also available in: Atom PDF