Installing Istio
- Before installing Istio, compile the source code and set up the Kubernetes cluster environment, as instructed in Installing Software by Compiling Source Code and Setting Up the Kubernetes Cluster Environment in the Containerd 1.4 Installation Guide (CentOS 8.1 and openEuler 20.03).
- The following installation procedure is for reference only. Install Istio based on your service scenario.
- By default, the Istio component is not scheduled to the primary node. Therefore, at least one subnode is required.
- Download Istio 1.8.1.
1 2
cd root wget https://github.com/istio/istio/releases/download/1.8.1/istio-1.8.1-linux-arm64.tar.gz
- Decompress the package.
1tar -xzvf istio-1.8.1-linux-arm64.tar.gz
- Go to the Istio package directory.
1cd istio-1.8.1
- Add istioctl to the environment variable (in the /etc/profile file).
1export PATH=$PWD/bin:$PATH
- Verify istioctl commands.
1istioctl version
- Install the Istio Operator.
Although Istio 1.6 and later versions support Linux and ARM64, the official image repository does not provide images for ARM64. Therefore, you need to change the repository address.
1istioctl operator init --hub=docker.io/querycapistio
- Install Istio.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106
kubectl create ns istio-system kubectl apply -f - <<EOF apiVersion: install.istio.io/v1alpha1 kind: IstioOperator metadata: name: example-iop namespace: istio-system spec: hub: docker.io/querycapistio meshConfig: accessLogFile: /dev/stdout components: egressGateways: - namespace: istio-system name: istio-egressgateway enabled: true k8s: affinity: nodeAffinity: preferredDuringSchedulingIgnoredDuringExecution: - preference: matchExpressions: - key: kubernetes.io/arch operator: In values: - arm64 weight: 2 requiredDuringSchedulingIgnoredDuringExecution: nodeSelectorTerms: - matchExpressions: - key: kubernetes.io/arch operator: In values: - arm64 resources: requests: cpu: 10m memory: 40Mi ingressGateways: - namespace: istio-system name: istio-ingressgateway enabled: true k8s: affinity: nodeAffinity: preferredDuringSchedulingIgnoredDuringExecution: - preference: matchExpressions: - key: kubernetes.io/arch operator: In values: - arm64 weight: 2 requiredDuringSchedulingIgnoredDuringExecution: nodeSelectorTerms: - matchExpressions: - key: kubernetes.io/arch operator: In values: - arm64 resources: requests: cpu: 10m memory: 40Mi service: ports: - port: 15021 targetPort: 15021 name: status-port - port: 80 targetPort: 8080 name: http2 - port: 443 targetPort: 8443 name: https - port: 31400 targetPort: 31400 name: tcp # This is the port where sni routing happens - port: 15443 targetPort: 15443 name: tls pilot: k8s: env: - name: PILOT_TRACE_SAMPLING value: "100" resources: requests: cpu: 10m memory: 100Mi values: global: proxy: resources: requests: cpu: 10m memory: 40Mi pilot: autoscaleEnabled: false gateways: istio-egressgateway: autoscaleEnabled: false istio-ingressgateway: autoscaleEnabled: false EOF
- Check whether Istio is successfully installed.
kubectl get pods -n istio-system
