Esegui la migrazione di Istio in bundle a Cloud Service Mesh
Mantieni tutto organizzato con le raccolte
Salva e classifica i contenuti in base alle tue preferenze.
Questi passaggi sono specifici per la versione in bundle di Istio inclusa per impostazione predefinita nel "componente aggiuntivo GKE" di Knative serving.
È importante eseguire ogni passaggio di questa procedura nell'ordine specificato.
Panoramica
In generale, la procedura per installare Cloud Service Mesh durante la migrazione dalla versione in bundle di Istio è la stessa procedura per eseguire un'installazione pulita di Cloud Service Mesh. In questo processo viene installata la versione 1.18 di Cloud Service Mesh con il piano di controllo in-cluster.
Installa Cloud Service Mesh versione 1.18
Utilizza la documentazione di installazione di Cloud Service Mesh per installare Cloud Service Mesh.
Prima di iniziare:
Per la migrazione, il gateway in entrata deve essere installato
separatamente durante i passaggi di configurazione successivi. Lo script di installazione non installerà il gateway in entrata per impostazione predefinita.
(Facoltativo) Se utilizzi l'autorità di certificazione Cloud Service Mesh (Mesh CA), devi includere anche il flag --ca mesh_ca nello script di installazione di Cloud Service Mesh.
In questa sezione, lo script di migrazione viene utilizzato per creare il gateway di ingresso Cloud Service Mesh nello spazio dei nomi gke-system.
Per la migrazione, viene utilizzato lo spazio dei nomi gke-system in modo che il gateway di ingresso venga inserito nello stesso spazio dei nomi utilizzato da "Istio in bundle" rimosso di recente. Di conseguenza, i pod di ingresso di Cloud Service Mesh possono assumere il controllo del traffico senza alcuna modifica di configurazione richiesta al servizio di ingresso. Ad esempio, non è necessario configurare un nuovo indirizzo IP esterno.
Per creare il gateway di ingresso all'interno del namespace gke-system,
esegui il seguente comando per avviare lo script di migrazione:
./migration-addon.sh--commandset-up-asm-ingress
L'output del terminale durante il processo è simile al seguente:
Setting up Cloud Service Mesh ingress. Note that the Cloud Service Mesh ingress is not
serving traffic at this step.
namespace/gke-system labeled
deployment.apps/istio-ingressgateway created
horizontalpodautoscaler.autoscaling/istio-ingressgateway created
role.rbac.authorization.k8s.io/istio-ingressgateway-sds created
rolebinding.rbac.authorization.k8s.io/istio-ingressgateway-sds created
Cloud Service Mesh ingress is successfully installed.
Verifica che il gateway di ingresso istio-ingrerssgateway sia in esecuzione nello spazio dei nomi gke-system eseguendo il seguente comando:
Tieni presente che il numero di pod istio-ingressgateway è intenzionalmente 0.
Dopo aver installato il componente del parco risorse Knative serving, è necessario eseguire un passaggio successivo per eseguire la migrazione di tutto il traffico all'ingresso di Cloud Service Mesh.
L'output del terminale durante il processo è simile al seguente:
Deleting Cloud Service Mesh ingress
deployment.apps "istio-ingressgateway" deleted
horizontalpodautoscaler.autoscaling "istio-ingressgateway" deleted
role.rbac.authorization.k8s.io "istio-ingressgateway-sds" deleted
rolebinding.rbac.authorization.k8s.io "istio-ingressgateway-sds" deleted
Cloud Service Mesh ingress is successfully deleted.
Per verificare che il gateway di ingresso Cloud Service Mesh sia stato rimosso, controlla che il servizio istio-ingressgateway non esista più nello spazio dei nomi gke-system:
[[["Facile da capire","easyToUnderstand","thumb-up"],["Il problema è stato risolto","solvedMyProblem","thumb-up"],["Altra","otherUp","thumb-up"]],[["Difficile da capire","hardToUnderstand","thumb-down"],["Informazioni o codice di esempio errati","incorrectInformationOrSampleCode","thumb-down"],["Mancano le informazioni o gli esempi di cui ho bisogno","missingTheInformationSamplesINeed","thumb-down"],["Problema di traduzione","translationIssue","thumb-down"],["Altra","otherDown","thumb-down"]],["Ultimo aggiornamento 2025-09-04 UTC."],[],[],null,["# Migrate the bundled Istio to Cloud Service Mesh\n\nThese steps are specific to the bundled version of Istio that is included by\ndefault with the Knative serving \"*GKE add-on*\".\n| **Important:** If the \"*Istio add-on* \" is installed on your cluster, you must instead perform the steps to [migrate the Istio add-on to Cloud Service Mesh](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/uninstall-istio-addon).\n\nSince the bundled version of Istio is uninstalled when you performed the\n[process of uninstalling the Knative serving \"*GKE add-on*\"](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/uninstall-addon),\nthe steps on this page install Cloud Service Mesh on your cluster and then\nconfigures your ingress gateway.\n\nBefore you begin\n----------------\n\n- You must first review and ensure that you meet the\n [requirements for upgrading](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade).\n\n- The commands on this page use the environment variables and migration script\n from the [upgrade preparation step](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/prepare).\n\n- It is important that you perform each step of this process in the\n [specified order](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade#upgrading).\n\nOverview\n--------\n\nIn general, the process for installing Cloud Service Mesh when migrating from the\nbundled version of Istio, is the same process as performing a clean\nCloud Service Mesh installation. In this process Cloud Service Mesh version\n1.18 is installed with the\n[In-cluster control plane](/service-mesh/v1.18/docs/supported-features).\n\nInstall Cloud Service Mesh version 1.18\n---------------------------------------\n\nYou use the Cloud Service Mesh installation documentation to install Cloud Service Mesh.\n\n**Before you begin**:\n\n- For the migration, the ingress gateway must be installed\n separately during the subsequent [configuration steps](#meshconfig). The\n installation script won't install the ingress gateway by default.\n\n- Optional: If you use Cloud Service Mesh certificate authority (Mesh CA), you must\n also include the `--ca mesh_ca` flag with the Cloud Service Mesh installation\n script.\n\n**To install Cloud Service Mesh**:\n\nFollow the steps in the Cloud Service Mesh documentation:\n[Install Cloud Service Mesh version 1.18](/service-mesh/v1.18/docs/unified-install/install-anthos-service-mesh)\n\nExample\n\n: The following is an example of the default command that includes the required\n flag:\n\n ./asmcli install \\\n --project_id ${PROJECT_ID} \\\n --cluster_name ${CLUSTER_NAME} \\\n --cluster_location ${CLUSTER_LOCATION} \\\n --ca mesh_ca \\\n --output_dir DIR_PATH \\\n --enable_all\n\n### Configure Cloud Service Mesh ingress\n\nIn this section, the [migration script](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/prepare) is used to\ncreate the Cloud Service Mesh ingress gateway within the `gke-system` namespace.\n\nFor the migration, the `gke-system` namespace is used so that the ingress\ngateway is placed within the same namespace used by the recently removed\n\"bundled Istio\". Therefore, the Cloud Service Mesh ingress pods can seamlessly\ntakeover traffic without any required configuration changes to the ingress\nservice. For example, you do not need to configure a new external IP address.\n\n1. To create the ingress gateway within the `gke-system` namespace,\n run the following command to start the migration script:\n\n ./migration-addon.sh --command set-up-asm-ingress\n\n The terminal output during the process looks similar to the following: \n\n Setting up Cloud Service Mesh ingress. Note that the Cloud Service Mesh ingress is not\n serving traffic at this step.\n namespace/gke-system labeled\n deployment.apps/istio-ingressgateway created\n horizontalpodautoscaler.autoscaling/istio-ingressgateway created\n role.rbac.authorization.k8s.io/istio-ingressgateway-sds created\n rolebinding.rbac.authorization.k8s.io/istio-ingressgateway-sds created\n Cloud Service Mesh ingress is successfully installed.\n\n2. Verify that the `istio-ingrerssgateway` ingress gateway is running in the\n `gke-system` namespace by running the following command:\n\n kubectl get deployment istio-ingressgateway -n gke-system\n\n Note that the number of `istio-ingressgateway` pods is intentionally `0`.\n After installing the Knative serving fleet component, there is a subsequent\n step to\n [migrate all traffic to the Cloud Service Mesh ingress](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/migrate-traffic).\n\nWhat's next\n-----------\n\n[Install the fleet component](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/fleet-install-script)\n\nRollback\n--------\n\nIf you need to rollback the changes that you made through the preceding steps,\nyou can use the migration script to:\n\n- Delete the Cloud Service Mesh ingress gateway.\n- Uninstall Cloud Service Mesh.\n\nTo rollback the Cloud Service Mesh configuration and installation:\n\n1. Run the following command to start the rollback.\n\n ./migration-addon.sh --command rollback-set-up-asm-ingress\n\n The terminal output during the process looks similar to the following: \n\n Deleting Cloud Service Mesh ingress\n deployment.apps \"istio-ingressgateway\" deleted\n horizontalpodautoscaler.autoscaling \"istio-ingressgateway\" deleted\n role.rbac.authorization.k8s.io \"istio-ingressgateway-sds\" deleted\n rolebinding.rbac.authorization.k8s.io \"istio-ingressgateway-sds\" deleted\n Cloud Service Mesh ingress is successfully deleted.\n\n2. To verify that the Cloud Service Mesh ingress gateway was removed, check that the\n `istio-ingressgateway` service no longer exists in the `gke-system`\n namespace:\n\n kubectl get deployment istio-ingressgateway -n gke-system\n\n3. [Uninstall Cloud Service Mesh](/service-mesh/v1.18/docs/uninstall)\n\n4. To continue rolling back all the changes to your installations original state,\n [rollback the Knative serving \"GKE add-on\"](/kubernetes-engine/enterprise/knative-serving/docs/install/on-gcp/upgrade/uninstall-addon#rollbackgkeaddon)."]]