Chapter 2. Running OpenShift Service Mesh 2.6 in the same cluster as OpenShift Service Mesh 3
If you are moving from Red Hat OpenShift Service Mesh v2.6, you can run OpenShift Service Mesh v2.6 side-by-side with OpenShift Service Mesh v3.0, in one cluster, without them interfering with each other.
2.1. Running OpenShift Service Mesh 2.6 and OpenShift Service Mesh 3 using multi-tenant deployment model
If you are moving from Red Hat OpenShift Service Mesh 2.6 from the default multi-tenant deployment model, you can run OpenShift Service Mesh 2.6 side-by-side with OpenShift Service Mesh 3.0, in one cluster, without them interfering with each other.
In OpenShift Service Mesh 2.6, you can check your deployment model from the ServiceMeshControlPlane
under spec.mode
:
Example ServiceMeshControlPlane
yaml
apiVersion: maistra.io/v2 kind: ServiceMeshControlPlane metadata: name: basic spec: mode: MultiTenant
Prerequisites
- You are running OpenShift Container Platform 4.14 or later.
You are running OpenShift Service Mesh 2.6.
ImportantIf you are not running OpenShift Service Mesh 2.6, you must upgrade to 2.6 before following this procedure. To upgrade to OpenShift Service Mesh version to 2.6, see: Upgrading Service Mesh 2.x
Procedure
- Install the OpenShift Service Mesh 3 Operator.
-
Create an
IstioCNI
resource in theistio-cni
namespace. Create an
Istio
resource in a different namespace than thenamespace
used in theServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6. In this example,istio-system3
is being used:Example
Istio
resource withistio-system3
kind: Istio piVersion: sailoperator.io/v1alpha1 metadata: name: ossm3 1 spec: namespace: istio-system3 2 values: meshConfig: discoverySelectors: 3 - matchExpressions: - key: maistra.io/member-of operator: DoesNotExist updateStrategy: type: InPlace version: v1.23.0
- 1
- Do not use
default
as the name. - 2
- Must be different from the namespace used in the
ServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6. - 3
- To ignore OpenShift Service Mesh 2.6 namespaces, configure the
discoverySelectors
section as shown. All other namespaces will be part of the OpenShift Service Mesh 3.0 mesh.
Deploy your workloads and label the namespaces with
istio.io/rev=ossm3
label by running the following command:$ oc label namespace <namespace-name> istio.io/rev=<revision-name>
NoteIf you have changed
spec.memberSelectors
inServiceMeshMemberRoll
in theServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6., then use theistio-injection=enabled
label for your OpenShift Service Mesh 3.0 workload namespaces.Confirm the application workloads are managed by their respective control planes by running the following command:
$ istioctl ps -i istio-system
Sample output
istio-system
$ istioctl ps -i istio-system NAME CLUSTER CDS LDS EDS RDS ECDS ISTIOD VERSION details-v1-7f46897b-88x4l.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 mongodb-v1-6cf7dc9885-7nlmq.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 mysqldb-v1-7c4c44b9b4-22b57.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 productpage-v1-6f9c6589cb-l6rvg.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v1-559b64556-f6b4l.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v2-8ddc4d65c-bztrg.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v2-mysql-cbc957476-m5j7w.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v1-847fb7c54d-7dwt7.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v2-5c7ff5b77b-5bpc4.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v3-5c5d764c9b-mk8vn.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8
Sample output
istio-system3
$ istioctl ps -i istio-system3 NAME CLUSTER CDS LDS EDS RDS ECDS ISTIOD VERSION details-v1-57f6466bdc-5krth.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 productpage-v1-5b84ccdddf-f8d9t.bookinfo2 Kubernetes SYNCED (2m39s) SYNCED (2m39s) SYNCED (2m34s) SYNCED (2m39s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 ratings-v1-fb764cb99-kx2dr.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v1-8bd5549cf-xqqmd.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v2-7f7cc8bf5c-5rvln.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v3-84f674b88c-ftcqg.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0
2.2. Running Red Hat OpenShift Service Mesh 2.6 and Red Hat OpenShift Service Mesh 3 using cluster-wide deployment model
If you are moving from Red Hat OpenShift Service Mesh 2.6 in a cluster-wide deployment model, you can run OpenShift Service Mesh 2.6 side-by-side with OpenShift Service Mesh 3.0, in one cluster, without them interfering with each other.
In OpenShift Service Mesh 2.6, you can check your deployment model from the ServiceMeshControlPlane
under spec.mode
:
Example ServiceMeshControlPlane
yaml
apiVersion: maistra.io/v2 kind: ServiceMeshControlPlane metadata: name: basic spec: mode: ClusterWide
To prevent conflicts with OpenShift Service Mesh 3.0 when using the OpenShift Service Mesh 2.6 cluster-wide deployment model, you need to configure the ServiceMeshControlPlane
resource to restrict namespaces to only those belonging to (SMProduct) 2.6.
Prerequisites
- You are running OpenShift Container Platform 4.14 or later.
You are running OpenShift Service Mesh 2.6.
ImportantIf you are not running OpenShift Service Mesh 2.6, you must upgrade to 2.6 before following this procedure. To upgrade to OpenShift Service Mesh version to 2.6, see: Upgrading Service Mesh 2.x
Procedure
Configure
discoverySelectors
, and set theENABLE_ENHANCED_RESOURCE_SCOPING
environment variable on the pilot container totrue
in your OpenShift Service Mesh 2.6ServiceMeshControlPlane
custom resource (CR):Example
ServiceMeshControlPlane
CRapiVersion: maistra.io/v2 kind: ServiceMeshControlPlane metadata: name: basic namespace: istio-system spec: version: v2.6 mode: ClusterWide meshConfig: discoverySelectors: - matchExpressions: - key: maistra.io/member-of operator: Exists runtime: components: pilot: container: env: ENABLE_ENHANCED_RESOURCE_SCOPING: 'true'
- Install the OpenShift Service Mesh 3 Operator.
-
Create an
IstioCNI
resource in theistio-cni
namespace. Create an
Istio
resource in a different namespace than the namespace used in theServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6. In this example,istio-system3
is being used:Example
Istio
resource withistio-system3
kind: Istio apiVersion: sailoperator.io/v1alpha1 metadata: name: ossm3 1 spec: namespace: istio-system3 2 values: meshConfig: discoverySelectors: 3 - matchExpressions: - key: maistra.io/member-of operator: DoesNotExist updateStrategy: type: InPlace version: v1.23.0
- 1
- Do not use
default
as the name. - 2
- Must be different from the namespace used in the
ServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6. - 3
- To ignore OpenShift Service Mesh 2.6 namespaces, configure the
discoverySelectors
section as shown. All other namespaces will be part of the OpenShift Service Mesh 3.0 mesh.
Deploy your workloads and label the namespaces with
istio.io/rev=ossm3
label by running the following command:$ oc label namespace <namespace-name> istio.io/rev=ossm3
NoteIf you have changed
spec.memberSelectors
inServiceMeshMemberRoll
in theServiceMeshControlPlane
resource in OpenShift Service Mesh 2.6., then use theistio-injection=enabled
label for your OpenShift Service Mesh 3.0 workload namespaces.Confirm the application workloads are managed by their respective control planes by running the following command:
$ istioctl ps -i istio-system
Sample output
istio-system
$ istioctl ps -i istio-system NAME CLUSTER CDS LDS EDS RDS ECDS ISTIOD VERSION details-v1-7f46897b-88x4l.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 mongodb-v1-6cf7dc9885-7nlmq.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 mysqldb-v1-7c4c44b9b4-22b57.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 productpage-v1-6f9c6589cb-l6rvg.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v1-559b64556-f6b4l.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v2-8ddc4d65c-bztrg.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 ratings-v2-mysql-cbc957476-m5j7w.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v1-847fb7c54d-7dwt7.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v2-5c7ff5b77b-5bpc4.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8 reviews-v3-5c5d764c9b-mk8vn.bookinfo Kubernetes SYNCED SYNCED SYNCED SYNCED NOT SENT istiod-install-istio-system-bd58bdcd5-2htkf 1.20.8
Sample output
istio-system3
$ istioctl ps -i istio-system3 NAME CLUSTER CDS LDS EDS RDS ECDS ISTIOD VERSION details-v1-57f6466bdc-5krth.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 productpage-v1-5b84ccdddf-f8d9t.bookinfo2 Kubernetes SYNCED (2m39s) SYNCED (2m39s) SYNCED (2m34s) SYNCED (2m39s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 ratings-v1-fb764cb99-kx2dr.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v1-8bd5549cf-xqqmd.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v2-7f7cc8bf5c-5rvln.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0 reviews-v3-84f674b88c-ftcqg.bookinfo2 Kubernetes SYNCED (2m40s) SYNCED (2m40s) SYNCED (2m34s) SYNCED (2m40s) IGNORED istiod-ossm3-5b46b6b8cb-gbjx6 1.23.0