multicluster

Manages the multicluster setup for Linkerd.

This command provides subcommands to manage the multicluster support functionality of Linkerd. You can use it to install the service mirror components on a cluster, manage credentials and link clusters together.

Examples

# Install multicluster addons.
linkerd --context=cluster-a multicluster install | kubectl --context=cluster-a apply -f -

# Extract mirroring cluster credentials from cluster A and install them on cluster B
linkerd --context=cluster-a multicluster link --cluster-name=target | kubectl apply --context=cluster-b -f -

Subcommands

allow

Outputs credential resources that allow service-mirror controllers to connect to this cluster

Flags

FlagUsage
--ignore-clusterIgnore cluster configuration
--namespaceThe destination namespace for the service account.
--service-account-nameThe name of the multicluster access service account

check

Check the multicluster extension for potential problems.

The check command will perform a series of checks to validate that the multicluster extension is configured correctly. If the command encounters a failure it will print additional information about the failure and exit with a non-zero exit code.

Examples

# Check that the multicluster extension is configured correctly
linkerd multicluster check

Flags

FlagUsage
--namespace
-n
--output
-o
Output format. One of: basic, json
--proxy
--waitMaximum allowed time for all tests to pass

gateways

Display stats information about the gateways in target clusters

Flags

FlagUsage
--cluster-namethe name of the target cluster
--gateway-namespacethe namespace in which the gateway resides on the target cluster
--time-window
-t
Time window (for example: “15s”, “1m”, “10m”, “1h”). Needs to be at least 15s.

install

Output Kubernetes configs to install the Linkerd multicluster add-on

Examples

# Default install.
linkerd multicluster install | kubectl apply -f -

The installation can be configured by using the --set, --values, --set-string and --set-file flags.
A full list of configurable values can be found at https://github.com/linkerd/linkerd2/blob/main/multicluster/charts/linkerd-multicluster/README.md

Flags

FlagUsage
--gatewayIf the gateway component should be installed
--gateway-nginx-imageThe nginx image to be used
--gateway-nginx-image-versionThe version of nginx to be used
--gateway-portThe port on the gateway used for all incoming traffic
--gateway-probe-portThe liveness check port of the gateway
--gateway-probe-secondsThe interval at which the gateway will be checked for being alive in seconds
--gateway-service-typeOverwrite Service type for gateway service
--namespaceThe namespace in which the multicluster add-on is to be installed. Must not be the control plane namespace.
--service-mirror-credentialsWhether to install the service account which can be used by service mirror components in source clusters to discover exported services
--setset values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--set-fileset values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2)
--set-stringset STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--values
-f
specify values in a YAML file or a URL (can specify multiple)
--waitWait for core control-plane components to be available

Outputs resources that allow another cluster to mirror services from this one

Examples

# To link the west cluster to east
linkerd --context=east multicluster link --cluster-name east | kubectl --context=west apply -f -

The command can be configured by using the --set, --values, --set-string and --set-file flags.
A full list of configurable values can be found at https://github.com/linkerd/linkerd2/blob/main/multicluster/charts/linkerd-multicluster-link/README.md

Flags

FlagUsage
--api-server-addressThe api server address of the target cluster
--cluster-nameCluster name
--control-plane-version(Development) Tag to be used for the service mirror controller image
--gateway-addressesIf specified overwrites gateway addresses when gateway service is not type LoadBalancer (comma separated list)
--gateway-nameThe name of the gateway service
--gateway-namespaceThe namespace of the gateway service
--log-levelLog level for the Multicluster components
--namespaceThe namespace for the service account
--registryDocker registry to pull service mirror controller image from
--selector
-l
Selector (label query) to filter which services in the target cluster to mirror
--service-account-nameThe name of the service account associated with the credentials
--service-mirror-retry-limitThe number of times a failed update from the target cluster is allowed to be retried
--setset values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--set-fileset values from respective files specified via the command line (can specify multiple or separate values with commas: key1=path1,key2=path2)
--set-stringset STRING values on the command line (can specify multiple or separate values with commas: key1=val1,key2=val2)
--values
-f
specify values in a YAML file or a URL (can specify multiple)

uninstall

Output Kubernetes configs to uninstall the Linkerd multicluster add-on

Flags

FlagUsage
--namespaceThe namespace in which the multicluster add-on is to be installed. Must not be the control plane namespace.

Outputs link resources for deletion

Flags

FlagUsage
--cluster-nameCluster name
--namespaceThe namespace for the service account