core: option to require msgrv2 even without encryption
Enabling msgr v2 and disabling msgr v1 currently requires enabling either encryption on the wire or compression on the wire. As more clients are running on the latest kernel, allow the clients to run on v2 even when encryption and compression are not enabled. Clusters that are fully running on v2 will more easily be able to change configuration between enabling or disabling msgr v2 features. Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
This commit is contained in:
11 files changed
+46
-1
No files matched your search
@@ -164,6 +164,9 @@ Configure the network that will be enabled for the cluster and services.
|
||||
* `ipFamily`: Specifies the network stack Ceph daemons should listen on.
|
||||
* `dualStack`: Specifies that Ceph daemon should listen on both IPv4 and IPv6 network stacks.
|
||||
* `connections`: Settings for network connections using Ceph's msgr2 protocol
|
||||
* `requireMsgr2`: Whether to require communication over msgr2. If true, the msgr v1 port (6789) will be disabled
|
||||
and clients will be required to connect to the Ceph cluster with the v2 port (3300).
|
||||
Requires a kernel that supports msgr2 (kernel 5.11 or CentOS 8.4 or newer). Default is false.
|
||||
* `encryption`: Settings for encryption on the wire to Ceph daemons
|
||||
* `enabled`: Whether to encrypt the data in transit across the wire to prevent eavesdropping the data on the network.
|
||||
The default is false. When encryption is enabled, all communication between clients and Ceph daemons, or between
|
||||
|
||||
@@ -8,6 +8,9 @@
|
||||
|
||||
## Features
|
||||
|
||||
- Added setting `requireMsgr2` on the CephCluster CR to allow clusters with a kernel of 5.11 or newer
|
||||
to fully communicate with msgr2 and disable the msgr1 port. This allows for more flexibility to enable
|
||||
msgr2 features such as encryption and compression on the wire.
|
||||
- Change `pspEnable` default value to `false` in helm charts.
|
||||
- [Bucket notifications and topics](https://rook.io/docs/rook/latest/Storage-Configuration/Object-Storage-RGW/ceph-object-bucket-notifications/)
|
||||
for object stores moved to stable from experimental.
|
||||
@@ -145,7 +145,24 @@ cephClusterSpec:
|
||||
ssl: true
|
||||
|
||||
# Network configuration, see: https://github.com/rook/rook/blob/master/Documentation/CRDs/ceph-cluster-crd.md#network-configuration-settings
|
||||
# network:
|
||||
network:
|
||||
connections:
|
||||
# Whether to encrypt the data in transit across the wire to prevent eavesdropping the data on the network.
|
||||
# The default is false. When encryption is enabled, all communication between clients and Ceph daemons, or between Ceph daemons will be encrypted.
|
||||
# When encryption is not enabled, clients still establish a strong initial authentication and data integrity is still validated with a crc check.
|
||||
# IMPORTANT: Encryption requires the 5.11 kernel for the latest nbd and cephfs drivers. Alternatively for testing only,
|
||||
# you can set the "mounter: rbd-nbd" in the rbd storage class, or "mounter: fuse" in the cephfs storage class.
|
||||
# The nbd and fuse drivers are *not* recommended in production since restarting the csi driver pod will disconnect the volumes.
|
||||
encryption:
|
||||
enabled: false
|
||||
# Whether to compress the data in transit across the wire. The default is false.
|
||||
# Requires Ceph Quincy (v17) or newer. Also see the kernel requirements above for encryption.
|
||||
compression:
|
||||
enabled: false
|
||||
# Whether to require communication over msgr2. If true, the msgr v1 port (6789) will be disabled
|
||||
# and clients will be required to connect to the Ceph cluster with the v2 port (3300).
|
||||
# Requires a kernel that supports msgr v2 (kernel 5.11 or CentOS 8.4 or newer).
|
||||
requireMsgr2: false
|
||||
# # enable host networking
|
||||
# provider: host
|
||||
# # EXPERIMENTAL: enable the Multus network provider
|
||||
|
||||
@@ -1875,6 +1875,9 @@ spec:
|
||||
description: Whether to encrypt the data in transit across the wire to prevent eavesdropping the data on the network. The default is not set. Even if encryption is not enabled, clients still establish a strong initial authentication for the connection and data integrity is still validated with a crc check. When encryption is enabled, all communication between clients and Ceph daemons, or between Ceph daemons will be encrypted.
|
||||
type: boolean
|
||||
type: object
|
||||
requireMsgr2:
|
||||
description: Whether to require msgr2 (port 3300) even if compression or encryption are not enabled. If true, the msgr1 port (6789) will be disabled. Requires a kernel that supports msgr2 (kernel 5.11 or CentOS 8.4 or newer).
|
||||
type: boolean
|
||||
type: object
|
||||
dualStack:
|
||||
description: DualStack determines whether Ceph daemons should listen on both IPv4 and IPv6
|
||||
|
||||
@@ -88,6 +88,10 @@ spec:
|
||||
# Requires Ceph Quincy (v17) or newer. Also see the kernel requirements above for encryption.
|
||||
compression:
|
||||
enabled: false
|
||||
# Whether to require communication over msgr2. If true, the msgr v1 port (6789) will be disabled
|
||||
# and clients will be required to connect to the Ceph cluster with the v2 port (3300).
|
||||
# Requires a kernel that supports msgr v2 (kernel 5.11 or CentOS 8.4 or newer).
|
||||
requireMsgr2: false
|
||||
# enable host networking
|
||||
#provider: host
|
||||
# enable the Multus network provider
|
||||
|
||||
@@ -1873,6 +1873,9 @@ spec:
|
||||
description: Whether to encrypt the data in transit across the wire to prevent eavesdropping the data on the network. The default is not set. Even if encryption is not enabled, clients still establish a strong initial authentication for the connection and data integrity is still validated with a crc check. When encryption is enabled, all communication between clients and Ceph daemons, or between Ceph daemons will be encrypted.
|
||||
type: boolean
|
||||
type: object
|
||||
requireMsgr2:
|
||||
description: Whether to require msgr2 (port 3300) even if compression or encryption are not enabled. If true, the msgr1 port (6789) will be disabled. Requires a kernel that supports msgr2 (kernel 5.11 or CentOS 8.4 or newer).
|
||||
type: boolean
|
||||
type: object
|
||||
dualStack:
|
||||
description: DualStack determines whether Ceph daemons should listen on both IPv4 and IPv6
|
||||
|
||||
@@ -33,6 +33,9 @@ func (c *ClusterSpec) RequireMsgr2() bool {
|
||||
if c.Network.Connections == nil {
|
||||
return false
|
||||
}
|
||||
if c.Network.Connections.RequireMsgr2 {
|
||||
return true
|
||||
}
|
||||
if c.Network.Connections.Compression != nil && c.Network.Connections.Compression.Enabled {
|
||||
return true
|
||||
}
|
||||
|
||||
@@ -2170,6 +2170,12 @@ type ConnectionsSpec struct {
|
||||
// +nullable
|
||||
// +optional
|
||||
Compression *CompressionSpec `json:"compression,omitempty"`
|
||||
|
||||
// Whether to require msgr2 (port 3300) even if compression or encryption are not enabled.
|
||||
// If true, the msgr1 port (6789) will be disabled.
|
||||
// Requires a kernel that supports msgr2 (kernel 5.11 or CentOS 8.4 or newer).
|
||||
// +optional
|
||||
RequireMsgr2 bool `json:"requireMsgr2,omitempty"`
|
||||
}
|
||||
|
||||
type EncryptionSpec struct {
|
||||
|
||||
@@ -159,6 +159,7 @@ spec:
|
||||
network:
|
||||
hostNetwork: false
|
||||
connections:
|
||||
requireMsgr2: ` + strconv.FormatBool(m.settings.RequireMsgr2) + `
|
||||
encryption:
|
||||
enabled: ` + strconv.FormatBool(m.settings.ConnectionsEncrypted) + `
|
||||
compression:
|
||||
|
||||
@@ -46,6 +46,7 @@ type TestCephSettings struct {
|
||||
DirectMountToolbox bool
|
||||
ConnectionsEncrypted bool
|
||||
ConnectionsCompressed bool
|
||||
RequireMsgr2 bool
|
||||
EnableVolumeReplication bool
|
||||
TestNFSCSI bool
|
||||
ChangeHostName bool
|
||||
|
||||
@@ -83,6 +83,7 @@ func (s *MultiClusterDeploySuite) SetupSuite() {
|
||||
EnableAdmissionController: true,
|
||||
RookVersion: installer.LocalBuildTag,
|
||||
CephVersion: installer.PacificVersion,
|
||||
RequireMsgr2: true,
|
||||
}
|
||||
s.settings.ApplyEnvVars()
|
||||
externalSettings := &installer.TestCephSettings{
|
||||
|
||||
Reference in new issue
Block a user