k8s安装istio

 

# 1、下载软件包并解压
[root@k8s-master1 istio]# ls
istio-1.11.1-linux-amd64.tar.gz
[root@k8s-master1 istio]# tar xf istio-1.11.1-linux-amd64.tar.gz 
[root@k8s-master1 istio]# cd istio-1.10.1/
[root@k8s-master1 istio-1.11.1]# ll
total 24
drwxr-x---  2 root root    22 Jun  5 04:44 bin    # 包含istioctl的客户端文件。istioctl工具用于手动注入Envoy sidecar代理
-rw-r--r--  1 root root 11348 Jun  5 04:44 LICENSE
drwxr-xr-x  5 root root    52 Jun  5 04:44 manifests
-rw-r-----  1 root root   854 Jun  5 04:44 manifest.yaml
-rw-r--r--  1 root root  5866 Jun  5 04:44 README.md
drwxr-xr-x 20 root root   332 Jun  5 04:44 samples    # 示例应用程序
drwxr-xr-x  3 root root    57 Jun  5 04:44 tools
[root@k8s-master1 istio-1.10.1]# cp bin/istioctl /usr/bin/

# 2、安装
[root@k8s-master1 istio]# istioctl install --set profile=demo -y
✔ Istio core installed                                                                                                 
✔ Istiod installed                                                                                                     
✔ Egress gateways installed                                                                                            
✔ Ingress gateways installed                                                                                           
✔ Installation complete                                                                                                Thank you for installing Istio 1.10.  Please take a few minutes to tell us about your install/upgrade experience!  https://forms.gle/KjkrDnMPByq7akrYA

# 3、验证istio是否部署成功
[root@k8s-master1 istio-1.11.1]# kubectl get pods -n istio-system
NAME                                    READY   STATUS    RESTARTS   AGE
istio-egressgateway-659cc7697b-42jdf    1/1     Running   0          18s
istio-ingressgateway-569f64cdf8-9xn7f   1/1     Running   0          18s
istiod-85c958cd6-j6p5n                  1/1     Running   0          22s

# 4、卸载istio集群,暂时不执行
~]# istioctl manifest generate --set profile=demo | kubectl delete -f -