Few Boundaries, Expandable Box

Istio

This quick guide will guide you on how to use Istio.

This quick guide will guide you on how to use Istio.

PortProtocolUsed by Description
15000TCPEnvoy Envoy admin port (commands/diagnostics)
15001TCPEnvoy Envoy Outbound
15006TCPEnvoy Envoy Inbound
15020HTTPEnvoy Istio agent Prometheus telemetry
15021HTTPEnvoy Health checks
15090HTTPEnvoy Envoy Prometheus telemetry
15010GRPCIstiod XDS and CA services (plaintext)
15012GRPCIstiod XDS and CA services (TLS)
8080HTTPIstiod Debug interface
443HTTPSIstiod Webhooks
15014HTTPMixer, Istiod Control plane monitoring
15443TLSIngress and Egress Gateways SNI
9090HTTPPrometheus Prometheus
42422TCPMixer Telemetry - Prometheus
15004HTTPMixer, Pilot Policy/Telemetry - mTLS
9091HTTPMixer Policy/Telemetry

Install

istioctl
1curl -L https://istio.io/downloadIstio | sh -# or visit https://istio.io/downloadIstio, execute the shell script which is download, or visit https://github.com/istio/istio/releases to download
2# Set evironment variable
3cd istio-1.19.3
4export PATH=$PWD/bin:$PATH
5# List setting template
6istioctl profile list
7istioctl install # default
8# Set istio (Optional)
9# k label namespace default istio-injection=enabled
10#kubectl label namespace default istio-injection=enabled

Uninstall

istioctl
1istioctl x uninstall --purge
2istioctl x uninstall <your original installation options>
3istioctl manifest generate <your original installation options> | kubectl delete -f -
4kubectl delete namespace istio-system

Add-ons

kubectl
1kubectl apply -f samples/addons
2kubectl rollout status deployment/kiali -n istio-system
3kubectl apply -f samples/addons/prometheus.yaml #grafana, jaeger, kiali, loki, prometheus
4istioctl dashboard kiali
5kubectl delete -f samples/addons
6

Optimize

istio-system
1kubectl edit cm istio-sidecar-injector -n istio-system
2# Change the requests as following json
3k delete po istiod-64d75d6b98-kg7x4 -n istio-system
istio yaml
1"resources": {
2  "limits": {
3    "cpu": "2000m",
4    "memory": "1024Mi"
5  },
6  "requests": {
7    "cpu": "100m", //need to change
8    "memory": "128Mi" // need to change
9  }
10},

Idiom

istioctl
1istioctl profile list
2istioctl profile dump default
3istioctl profile diff default demo
4istioctl manifest generate > $HOME/generated-manifest.yaml
5istioctl verify-install -f $HOME/generated-manifest.yaml

Issue

JWT Issue
1info    JWT policy is first-party-jwt
2Missing JWT token, can't use in process SDS /var/run/secrets/kubernetes.io/serviceaccount/tokenstat /var/run/secrets/kubernetes.io/serviceaccount/token: no such file or directory
3Missing JWT, can't authenticate with control plane. Try using plain text (15010)
deployment > template > spec (automountServiceAccountToken: true)
Upload File Issue
1kubectl describe pod kube-apiserver -n kube-system | grep 'service-cluster-ip-range'
2# --service-cluster-ip-range=10.96.0.0/12
3./istioctl profile list
4./istioctl install --set values.global.proxy.includeIPRanges="10.96.0.0/12"
5# 清除值
6#./istioctl install --set values.global.proxy.includeIPRanges=""