Technical architectural analysis, practical configuration manifests, and deployment instructions for istioctl CLI Sheet: Istio Proxy Diagnosis.
Linked Page
Cluster Control
install
Apply the Istio manifest to install or reconfigure Istio on your cluster.
uninstall
Remove Istio from the cluster
upgrade
Upgrade your Istio control plane immediately
manifest
Istio manifest-related commands
istioctl diff #Compare manifests and generate diff
istioctl generate #Generates an Istio install manifest
istioctl install #Applies an Istio manifest, installing or reconfiguring Istio on a cluster.
operator
Commands related to the Istio operator controller.
istioctl operator dump
remote-clusters
Lists the remote clusters to which each istiod instance is connected.
istioctl remote-clusters
Istio Management
admin
control plane (istiod) configuration management
#Aliases: admin, istiod
istioctl admin log
kube-inject
Inserting the Istio sidecar into your Kubernetes Pod resources
Examples:
# Update resources on the fly before applying.
kubectl apply -f <(istioctl kube-inject -f <resource.yaml>)
# Create a persistent version of the deployment with Istio sidecar injected.
istioctl kube-inject -f deployment.yaml -o deployment-injected.yaml
# Update an existing deployment.
kubectl get deployment -o yaml | istioctl kube-inject -f - | kubectl apply -f -
# Capture cluster configuration for later use with kube-inject
kubectl -n istio-system get cm istio-sidecar-injector -o jsonpath="{.data.config}" > /tmp/inj-template.tmpl
kubectl -n istio-system get cm istio -o jsonpath="{.data.mesh}" > /tmp/mesh.yaml
kubectl -n istio-system get cm istio-sidecar-injector -o jsonpath="{.data.values}" > /tmp/values.json
# Use kube-inject based on captured configuration
istioctl kube-inject -f samples/bookinfo/platform/kube/bookinfo.yaml \
--injectConfigFile /tmp/inj-template.tmpl \
--meshConfigFile /tmp/mesh.yaml \
--valuesFile /tmp/values.json
Flags:
--authority string XDS Subject Alternative Name (for example istiod.istio-system.svc)
--cert-dir string XDS Endpoint certificate directory
-f, --filename string Input Kubernetes resource filename
-h, --help help for kube-inject
--injectConfigFile string Injection configuration filename. Cannot be used with --injectConfigMapName
--insecure Skip server certificate and domain verification. (NOT SECURE!)
--meshConfigFile string Mesh configuration filename. Takes precedence over --meshConfigMapName if set
--meshConfigMapName string ConfigMap name for Istio mesh configuration, key should be "mesh" (default "istio")
--operatorFileName string Path to file containing IstioOperator custom resources. If configs from files like meshConfigFile, valuesFile are provided, they will be overridden by iop config values.
-o, --output string Modified output Kubernetes resource filename
--plaintext Use plain-text HTTP/2 when connecting to server (no TLS).
-r, --revision string Control plane revision
--timeout duration The duration to wait before failing (default 30s)
--valuesFile string Injection values configuration filename.
--webhookConfig string MutatingWebhookConfiguration name for Istio (default "istio-sidecar-injector")
--xds-address string XDS Endpoint
--xds-label string Istiod pod label selector
--xds-port int Istiod pod port (default 15012)
profile
Commands related to Istio Configuration profiles
# ๋ชฉ๋ก ์กฐํ
istioctl profile list
# ํ์ฌ ํ๋กํ ์กฐํ
istioctl profile dump
# ํน์ ํ๋กํ ์กฐํ
istioctl profile dump $profile
# ๋ ํ๋กํ ๋น๊ต
istioctl profile diff $profile1 $profile2
tag
Group of commands used to interact with revision tags
istioctl tag list
create-remote-secret
Create a secret containing your credentials to allow Istio to access the remote Kubernetes apiserver.
Examples:
# Create a secret to access cluster c0's apiserver and install it in cluster c1.
istioctl --kubeconfig=c0.yaml create-remote-secret --name c0 \
| kubectl --kubeconfig=c1.yaml apply -f -
# Delete a secret that was previously installed in c1
istioctl --kubeconfig=c0.yaml create-remote-secret --name c0 \
| kubectl --kubeconfig=c1.yaml delete -f -
# Create a secret access a remote cluster with an auth plugin
istioctl --kubeconfig=c0.yaml create-remote-secret --name c0 --auth-type=plugin --auth-plugin-name=gcp \
| kubectl --kubeconfig=c1.yaml apply -f -
Flags:
--auth-plugin-config stringToString Authenticator plug-in configuration. --auth-type=plugin must be set with this option (default [])
--auth-plugin-name string Authenticator plug-in name. --auth-type=plugin must be set with this option
--auth-type RemoteSecretAuthType Type of authentication to use. supported values = [bearer-token plugin] (default bearer-token)
--create-service-account If true, the service account needed for creating the remote secret will be created if it doesn't exist. (default true)
-h, --help help for create-remote-secret
-d, --manifests string Specify a path to a directory of charts and profiles
(e.g. ~/Downloads/istio-1.21.1/manifests).
--name string Name of the local cluster whose credentials are stored in the secret. If a name is not specified the kube-system namespace's UUID of the local cluster will be used.
--secret-name string The name of the specific secret to use from the service-account. Needed when there are multiple secrets in the service account.
--server string The address and port of the Kubernetes API server.
--service-account string Create a secret with this service account's credentials. Default value is "istio-reader-service-account" if --type is "remote", "istiod" if --type is "config".
--type SecretType Type of the generated secret. supported values = [remote config] (default remote)
dashboard
Access to the Istio web UI
#Aliases: d
istioctl d controlz -- Open ControlZ web UI
istioctl d istiod-debug -- Open Istio debug web UI
istioctl d envoy -- Open Envoy admin web UI
istioctl d proxy -- Open admin web UI for a proxy
istioctl d grafana -- Open Grafana web UI using "app.kubernetes.io/name=grafana"
istioctl d jaeger -- Open Jaeger web UI using "app=jaeger"
istioctl d kiali -- Open Kiali web UI
istioctl d prometheus -- Open Prometheus web UI
istioctl d skywalking -- Open SkyWalking UI
istioctl d zipkin -- Open Zipkin web UI
#istiod
istioctl dashboard controlz deploy/istiod
istioctl dashboard istiod-debug deploy/istiod
#envoy description #pod
istioctl dashboard envoy postgresql-0.datastore
Test Commands
## Istio ์ค์น ์ํ ํ์ธ
istioctl verify-install
## ํด๋ฌ์คํฐ ์ ๋ณด ๋ฐ ๋ก๊ทธ ์บก์ฒ ์ง์ ๋๊ตฌ์
๋๋ค.
istioctl bug-report
## Istio ๊ตฌ์ฑ ๋ถ์ ๋ฐ ๊ฒ์ฆ ๋ฉ์์ง ์ธ์
istioctl analyze -n $namespace
## Istio policy ๋ฐ rules ํ์ผ ๊ฒ์ฆ
#Aliases: validate, v
istioctl validate -f $policy_or_rules_yaml
istioctl v -f $policy_or_rules_yaml
Proxy
proxy-config
Aliases: proxy-config, pc
Retrieve information about proxy configuration from Envoy [kube only]
cluster
#gateway pod๋ก cluster proxy config ์กฐํ
#Aliases: cluster, clusters, c
## ์ ์ฒด ์กฐํ
istioctl pc c -n $namespace $gatewayPod
istioctl pc c -n $namespace $gatewayPod -o json | jq '.[]'
Table Description
SERVICE FQDN: Fully Qualified Domain NameDIRECTIONoutbound:TYPEEDS:STATIC:STRICT_DNS:PORT/SUBSET/DESTINATION RULE
listener
#Pod Listener proxy config ์กฐํ
#Aliases: listener, listeners, l
## ์ ์ฒด ์กฐํ
istioctl pc l -n $namespace $pod
## Listner filter address
istioctl pc l -n $namespace $pod --address $address
istioctl pc l -n $namespace $pod --address $address -o json | jq '.[]'
## Listner filter port
istioctl pc l -n $namespace $pod --port $port
istioctl pc l -n $namespace $pod --port $port -o json | jq '.[]'
Table Description
- Listener target
ADDRESSES: Listener IP- Service IP or
0.0.0.0
- Service IP or
PORT: Listener Port- Listener rule
-
MATCH:-
Transโ
raw_buffer
โtls -
Appโ
http/1.1,h2c
โistio-http/1.0,istio-http/1.1,istio-h2
โTCP -
Addrโ
0.0.0.0/0 -
ALL
-
-
DESTINATION: Destination-
PassthroughCluster: -
InboundPassthroughClusterIpv4: -
Route: $PORT: -
Route: $SERVICE_FQDN:$PORT: -
Cluster: outbound|$PORT||$SERVICE_FQDN: -
Cluster: inbound|$PORT||: -
Non-HTTP/Non-TCP:
-
-
proxy-status
Aliases: proxy-status, ps
Retrieves the sync status of each Envoy in the mesh. [kube only]
https://istio.io/latest/docs/ops/diagnostic-tools/proxy-cmd/
istioctl proxy-status
istioctl ps
Terminology
- Columns
CDS: Cluster Discovery ServiceLDS: Listener Discovery ServiceEDS: Endpoint Discovery ServiceRDS: Route Discovery ServiceECDS: Extension Config Discovery Service- Values
SYNCED: This means that Envoy has confirmed the last configuration sent by Istiod.NOT SENT: This means that Istiod did not send anything to Envoy. This is usually because there is nothing to send to Istiod.STALE: This means that Istiod sent an update to Envoy, but it was not approved. This usually indicates a networking issue between Envoy and Istiod, or a bug in Istio itself.
ETC
authz
(Authentication is experimental. Use istioctl experimental authentication)
experimental
Experimental commands that may be modified or deprecated
authz (Inspect Istio AuthorizationPolicy)
check-inject (Check the injection status or inject-ability of a given resource, explains why it is (or will be) injected or not)
config (Configure istioctl defaults)
describe (Describe resource and related Istio configuration)
envoy-stats (Retrieves Envoy metrics in the specified pod)
injector (List sidecar injector and sidecar versions)
internal-debug (Retrieves the debug information of istio)
metrics (Prints the metrics for the specified workload(s) when running in Kubernetes.)
precheck (Check whether Istio can safely be installed or upgraded)
proxy-status (Retrieves the synchronization status of each Envoy in the mesh)
version (Prints out build version information)
wait (Wait for an Istio resource)
waypoint (Manage waypoint configuration)
workload (Commands to assist in configuring and deploying workloads running on VMs and other non-Kubernetes environments)
mhkim@fredric:~/playgrounds-fredric/iac/2.helm/cicd/argo-workflows$ istioctl experimental
authz (Inspect Istio AuthorizationPolicy)
check-inject (Check the injection status or inject-ability of a given resource, explains why it is (or will be) injected or not)
config (Configure istioctl defaults)
describe (Describe resource and related Istio configuration)
envoy-stats (Retrieves Envoy metrics in the specified pod)
injector (List sidecar injector and sidecar versions)
internal-debug (Retrieves the debug information of istio)
metrics (Prints the metrics for the specified workload(s) when running in Kubernetes.)
precheck (Check whether Istio can safely be installed or upgraded)
proxy-status (Retrieves the synchronization status of each Envoy in the mesh)
version (Prints out build version information)
wait (Wait for an Istio resource)
waypoint (Manage waypoint configuration)
workload (Commands to assist in configuring and deploying workloads running on VMs and other non-Kubernetes environments)
Flags
--context string Kubernetes configuration context
-h, --help help for istioctl
-i, --istioNamespace string Istio system namespace (default "istio-system")
-c, --kubeconfig string Kubernetes configuration file
-n, --namespace string Kubernetes namespace
--vklog Level number for the log level verbosity. Like -v flag. ex: --vklog=9
Features




Leave a Reply