This guide explains how to upgrade Anthos Service Mesh from version 1.4.5+ to version 1.4.10 on Anthos clusters on VMware. If you want to upgrade to Anthos Service Mesh 1.5, see the 1.5 version of Upgrading Anthos Service Mesh on premises.
Redeploying the Anthos Service Mesh control plane components takes about 5 to 10 minutes to complete. Additionally, you need to inject new sidecar proxies in all of your workloads so they are updated with the current Anthos Service Mesh version. The time it takes to update the sidecar proxies depends on many factors, such as the number of pods, the number of nodes, deployment scaling settings, pod disruption budgets, and other configuration settings. A rough estimate of the time that it takes to update the sidecar proxies is 100 pods per minute.
Preparing for the upgrade
This section outlines the steps that you take to upgrade Anthos Service Mesh.
Review the Supported features and this upgrade guide to become familiar with the features and the upgrade process.
Review your authorization policies to see if they need to be updated.
If you enabled optional features when you installed the previous version of Anthos Service Mesh by adding
--set values
flags to theistioctl apply
command line, you need to use the same flags when you runistioctl apply
to install 1.4.10.If you enabled optional features when you installed the previous version of Anthos Service Mesh by adding the
-f
flag to theistioctl apply
command line to specify a YAML file, you must specify the same file (or a file with the same content) when you runistioctl apply
to upgrade to 1.4.10.Schedule a downtime. Upgrading can take up to 1 hour, depending on the scale of the cluster. Note that this doesn't include the time that you need to redeploy workloads to update sidecar proxies.
Setting up your environment
On your local machine, install and initialize the Google Cloud CLI.
If you already have the gcloud CLI installed:
Authenticate with the gcloud CLI:
gcloud auth login
Update the components:
gcloud components update
Install
kubectl
:gcloud components install kubectl
Get the project ID of the project that the cluster was created in:
gcloud
gcloud projects list
Console
In the Google Cloud console, go to the Dashboard page:
Click the Select from drop-down list at the top of the page. In the Select from window that appears, select your project. The project ID is displayed on the project Dashboard Project info card.
Set the default project ID for the Google Cloud CLI:
gcloud config set project PROJECT_ID
Setting credentials and permissions
-
Ensure that you have
kubectl
for the user cluster where you want to install Anthos Service Mesh. Note that you can install Anthos Service Mesh only on a user cluster, not an admin cluster. -
Grant cluster admin permissions to the current user. You need these
permissions to create the necessary
role based access
control (RBAC) rules for Anthos Service Mesh:
kubectl create clusterrolebinding cluster-admin-binding \ --clusterrole=cluster-admin \ --user="$(gcloud config get-value core/account)"
If you see the
"cluster-admin-binding" already exists
error, you can safely ignore it and continue with the existing cluster-admin-binding.
Downloading the installation file
-
Download the Anthos Service Mesh installation file to your current working
directory:
curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-linux.tar.gz
-
Download the signature file and use
openssl
to verify the signature:curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-linux.tar.gz.1.sig openssl dgst -verify - -signature istio-1.4.10-asm.18-linux.tar.gz.1.sig istio-1.4.10-asm.18-linux.tar.gz <<'EOF' -----BEGIN PUBLIC KEY----- MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWZrGCUaJJr1H8a36sG4UUoXvlXvZ wQfk16sxprI2gOJ2vFFggdq3ixF2h4qNBt0kI7ciDhgpwS8t+/960IsIgw== -----END PUBLIC KEY----- EOF
The expected output is:
Verified OK
-
Download the Anthos Service Mesh installation file to your current working
directory:
curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-osx.tar.gz
-
Download the signature file and use
openssl
to verify the signature:curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-osx.tar.gz.1.sig openssl dgst -sha256 -verify /dev/stdin -signature istio-1.4.10-asm.18-osx.tar.gz.1.sig istio-1.4.10-asm.18-osx.tar.gz <<'EOF' -----BEGIN PUBLIC KEY----- MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWZrGCUaJJr1H8a36sG4UUoXvlXvZ wQfk16sxprI2gOJ2vFFggdq3ixF2h4qNBt0kI7ciDhgpwS8t+/960IsIgw== -----END PUBLIC KEY----- EOF
The expected output is:
Verified OK
-
Download the Anthos Service Mesh installation file to your current working
directory:
curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-win.zip
-
Download the signature file and use
openssl
to verify the signature:curl -LO https://storage.googleapis.com/gke-release/asm/istio-1.4.10-asm.18-win.zip.1.sig openssl dgst -verify - -signature istio-1.4.10-asm.18-win.zip.1.sig istio-1.4.10-asm.18-win.zip <<'EOF' -----BEGIN PUBLIC KEY----- MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWZrGCUaJJr1H8a36sG4UUoXvlXvZ wQfk16sxprI2gOJ2vFFggdq3ixF2h4qNBt0kI7ciDhgpwS8t+/960IsIgw== -----END PUBLIC KEY----- EOF
The expected output is:
Verified OK
-
Extract the contents of the file to any location on your file system. For
example, to extract the contents to the current working directory:
tar xzf istio-1.4.10-asm.18-linux.tar.gz
The command creates an installation directory in your current working directory named
istio-1.4.10-asm.18
that contains:- Sample applications in
samples
- The following tools in the
bin
directory:istioctl
: You useistioctl
to install Anthos Service Mesh.asmctl
: You useasmctl
to help validate your security configuration after installing Anthos Service Mesh. (Currently,asmctl
isn't supported on Anthos clusters on VMware.)
- Sample applications in
-
Ensure that you're in the Anthos Service Mesh installation's root directory.
cd istio-1.4.10-asm.18
-
For convenience, add the tools in the
/bin
directory to your PATH:export PATH=$PWD/bin:$PATH
Linux
Mac OS
Windows
Upgrading Anthos Service Mesh
This section explains how to upgrade Anthos Service Mesh and enable the Supported default features listed on the Supported features page. For information on enabling the Supported optional features, see Enabling optional features.
To upgrade Anthos Service Mesh:
Choose one of the following commands to configure Anthos Service Mesh in
PERMISSIVE
mutual TLS (mTLS)
authentication mode or STRICT
mTLS mode.
PERMISSIVE mTLS
istioctl manifest apply --set profile=asm-onprem
STRICT mTLS
istioctl manifest apply --set profile=asm-onprem \ --set values.global.mtls.enabled=true
Check the control plane components
Upgrading requires reinstalling the control plane components, which takes
about 5 to 10 minutes to complete. The old control plane components are
terminated and then deleted as the new components are installed. You can check
the progress by looking at the value in the AGE
column of the workloads.
kubectl get pod -n istio-system
Example output
NAME READY STATUS RESTARTS AGE istio-citadel-64f6d7c7c7-jtmw7 1/1 Running 0 38s istio-galley-6b4878d445-c4rtt 1/2 Running 0 37s istio-ingressgateway-7866c5c88f-llp28 0/1 Running 0 37s istio-ingressgateway-7866c5c88f-m9sck 1/1 Terminating 0 25m istio-pilot-7f4fdcb89c-r98jl 1/2 Running 0 37s istio-sidecar-injector-65cbd565b9-q4wm9 1/1 Running 0 37s promsd-78dfdf7c7d-2bhr6 2/2 Running 1 37s
In this example, there are two instances of istio-ingressgateway
. The instance
with 25m
in the AGE
column is being terminated. All the other components are
newly installed.
Updating sidecar proxies
Anthos Service Mesh uses sidecar proxies to enhance network security, reliability, and observability. With Anthos Service Mesh, these functions are abstracted away from the application's primary container and implemented in a common out-of-process proxy delivered as a separate container in the same Pod.
Any workloads that were running on your cluster before you installed Anthos Service Mesh need to have the sidecar proxy injected or updated so they have the current Anthos Service Mesh version. Before you deploy new workloads, make sure to configure sidecar proxy injection so that Anthos Service Mesh can monitor and secure traffic.You can enable automatic sidecar injection with one command, for example:
kubectl label namespace NAMESPACE istio-injection=enabled --overwrite
where NAMESPACE
is the name of the
namespace
for your application's services or default
if you didn't explicitly create
a namespace.
For more information, see Injecting sidecar proxies.