• Logo
    LXD
  • canonical.com/lxd
  • More resources
    • Install LXD
    • Manage LXD
    • Forum
    • GitHub
Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
LXD
  • LXD
  • Tutorials
    • First steps with LXD
    • Getting started with the UI
  • How-to guides
    • Getting started
      • Install LXD
      • Initialize LXD
      • Access the UI
      • Access documentation locally
    • LXD server and client
      • Expose LXD to the network
      • Configure the LXD server
      • Configure OIDC authentication with Auth0
      • Configure OIDC authentication with Ory Hydra
      • Configure OIDC authentication with Keycloak
      • Configure OIDC authentication with Microsoft Entra ID
      • Add remote servers
      • Add command aliases
    • Instances
      • Create instances
      • Configure instances
      • Manage instances
      • Use profiles
      • Troubleshoot errors
      • Auto attach Ubuntu Pro
      • Access files
      • Access the console
      • Run commands
      • Use cloud-init
      • Add a routed NIC to a VM
      • Back up instances
      • Migrate instances
      • Import existing machines
      • Pass NVIDIA GPUs
    • Images
      • Use remote images
      • Manage images
      • Associate profiles
      • Copy and import images
      • Create images
    • Projects
      • Create and configure
      • Work with projects
      • Confine users to projects
    • Storage
      • Manage pools
      • Manage volumes
      • Manage buckets
      • Create an instance in a pool
      • Back up a volume
      • Move or copy a volume
    • Networking
      • Create a network
      • Configure a network
      • Configure as BGP server
      • Configure network ACLs
      • Configure forwards
      • Configure network zones
      • Configure your firewall
      • Integrate with resolved
      • Set up OVN
      • Configure load balancers
      • Configure peer routing
      • Display IPAM information
    • Clustering
      • Form a cluster
      • Manage a cluster
      • Configure networks
      • Configure storage
      • Manage instances
      • Set up cluster groups
      • Recover a cluster
      • Create cluster links
      • Manage cluster links
    • Production setup
      • Benchmark performance
      • Increase bandwidth
      • Monitor metrics
      • Send logs to Loki
      • Set up Grafana
      • Back up a server
      • Recover instances
    • Manage the snap
    • Troubleshooting
      • Configure your firewall
      • Troubleshoot instances
      • Troubleshoot Dqlite
      • Debug LXD
      • Frequently asked
    • Get support
    • Contribute to LXD
  • Explanation
    • lxd and lxc
    • Containers and VMs
    • Local and remote images
    • Storage pools, volumes, and buckets
    • Networking setups
    • The LXD Dqlite database
    • lxc show and info
    • Remote API authentication
    • Remote API authorization
    • Instances grouping with projects
    • Clusters
    • Performance tuning
    • Security
    • Privilege delegation using BPF Token
  • Reference
    • Requirements
    • Architectures
    • Releases and snap
    • Remote image servers
    • Image format
    • Guest OS compatibility
    • Container environment
    • Configuration option index
    • Server configuration
    • Instance configuration
      • Instance properties
      • Instance options
      • Devices
        • Standard devices
        • Type: none
        • Type: nic
        • Type: disk
        • Type: unix-char
        • Type: unix-block
        • Type: usb
        • Type: gpu
        • Type: infiniband
        • Type: proxy
        • Type: unix-hotplug
        • Type: tpm
        • Type: pci
      • Units for storage and network limits
    • Preseed YAML file fields
    • Project configuration
    • Storage drivers
      • Btrfs - btrfs
      • CephFS - cephfs
      • Ceph Object - cephobject
      • Ceph RBD - ceph
      • Dell PowerFlex - powerflex
      • Pure Storage - pure
      • Directory - dir
      • LVM - lvm
      • ZFS - zfs
    • Networks
      • Bridge network
      • OVN network
      • Macvlan network
      • Physical network
      • SR-IOV network
    • Clusters
      • Cluster member configuration
      • Cluster link configuration
    • Production server settings
    • Provided metrics
    • Permissions
    • REST API
      • Main API documentation
      • Main API specification
      • Main API extensions
      • Events API documentation
      • Instance API
    • Man pages
      • lxc
    • Internals
      • Environment variables
      • UEFI variables for VMs
      • Daemon behavior
      • System call interception
      • User namespace setup
      • OVN implementation
      • VM live migration implementation
    • Project repository
    • Image server
Back to top
View this page

How to manage cluster links¶

View cluster links¶

To list all cluster links (that you have permission to see), run:

lxc cluster link list

To list all cluster links (that you have permission to see), send the following request:

lxc query --request GET /1.0/cluster/links

To display detailed information about each cluster link, use Recursion:

lxc query --request GET /1.0/cluster/links?recursion=1

See GET /1.0/cluster/links and GET /1.0/cluster/links?recursion=1 for more information.

To view the full configuration of a specific cluster link, run:

lxc cluster link show <name>
lxc query --request GET /1.0/cluster/links/<name>

See GET /1.0/cluster/links/{name} for more information.

To view detailed information about the state of a specific cluster link, run:

lxc cluster link info <name>
lxc query --request GET /1.0/cluster/links/<name>/state

See GET /1.0/cluster/links/{name}/state for more information.

Manage cluster link permissions¶

To modify the permissions of a cluster link, add its identity to authentication groups. See Manage permissions for more information.

For example, you can create an authentication group with server viewer permissions and add the cluster link identity to it:

lxc auth group create viewers
lxc auth group permission add viewers server viewer
lxc auth identity group add tls/<cluster-link-name> viewers

Alternatively, you can specify an authentication group when creating a cluster link, which will automatically assign the cluster link identity to that group.

Example:

lxc cluster link create cluster_b --auth-group server-admins

Configure a cluster link¶

See Cluster link configuration for more details on cluster link configuration options.

There are multiple ways to update the configuration for a cluster link.

You can edit the entire configuration at once:

To edit a cluster link in your default text editor, enter the following command:

lxc cluster link edit <name>

To edit a cluster link, send the following request:

lxc query --request PUT /1.0/cluster/links/<name> --data "<link_configuration>"

See PUT /1.0/cluster/links/{name} for more information.

You can update a single property for a cluster link:

Use the set command with the --property flag:

lxc cluster link set <cluster-link-name> --property <key>=<value>

For example, to update the description property:

lxc cluster link set cluster_b --property description="Backup cluster in data center 2"

To modify a specific property, send the following request:

lxc query --request PATCH /1.0/cluster/links/<name> --data '{"<key>": "<value>"}'

Example:

lxc query --request PATCH /1.0/cluster/links/cluster_b --data '{"description": "Backup cluster in data center B"}'

See PATCH /1.0/cluster/links/{name} for more information.

Cluster links have the following properties:

description

Description of the cluster link

Key: description
Type:

string

Required:

no

name

The name of the cluster link

Key: name
Type:

string

Required:

no

You can also update a single configuration option for a cluster link. Run:

lxc cluster link set <name> <key>=<value>
lxc query --request PATCH /1.0/cluster/links/<name> --data '{"config": <config>}'

See PATCH /1.0/cluster/links/{name} for more information.

Delete a cluster link¶

To delete a cluster link, run:

lxc cluster link delete <name>
lxc query --request DELETE /1.0/cluster/links/<name>

See DELETE /1.0/cluster-links/{name} for more information.

Note

Deleting a cluster link removes the established trust and deletes the associated identity on the local cluster. If you only run the command on one cluster, the other cluster will still have the cluster link identity and trust established (still allowing requests from the linked cluster). To fully disconnect the clusters, run the command on both clusters.

Next
Production setup
Previous
How to create cluster links
Copyright © 2014-2025 LXD contributors
Last updated on Aug 11, 2025
Show source
Thanks to our contributor!
  • Kadin Sayani
Ask a question on Discourse
Ask a question on Matrix
Open a GitHub issue for this page
Edit this page on GitHub
Contents
  • How to manage cluster links
    • View cluster links
    • Manage cluster link permissions
    • Configure a cluster link
    • Delete a cluster link