LXC.LIST(1)

πŸ“¦
version 5.21.6 Β· 3 versions
, in opensuse-leap 16.0

πŸ¦‹ NAME

lxc-list β€” the part where you list your instances, bestie πŸ’…

(context so you're not confused: this whole page lives under LXD - Command line client(1) 🫢)


✨ SYNOPSIS ✨

lxc list [:] [...] [flags]

🌸 DESCRIPTION 🌸

Okay so real talk, here's what it does: it lists instances. That's the whole vibe.

Default column layout: ns46tS Fast column layout: nsacPt

Now, the filters. Pay attention, this is the good part πŸ‘‘

  • A single keyword like "web" β€” that lists any instance with a name starting with "web".
  • A regular expression on the instance name. (e.g. .*web.*01$).
  • A key/value pair referring to a configuration item. For those, the namespace can be abbreviated to the smallest unambiguous identifier.
  • A key/value pair where the key is a shorthand. Multiple values must be delimited by ,. Available shorthands:
    • type={instance type}
    • status={instance current lifecycle status}
    • architecture={instance architecture}
    • location={location name}
    • ipv4={ip or CIDR}
    • ipv6={ip or CIDR}

Examples: (literally the manpage's own, I'm not making these up)

  • "user.blah=abc" will list all instances with the "blah" user property set to "abc".
  • "u.blah=abc" will do the same
  • "security.privileged=true" will list all privileged instances
  • "s.privileged=true" will do the same
  • "type=container" will list all container instances
  • "type=container status=running" will list all running container instances

A regular expression matching a configuration item or its value. (e.g. volatile.eth0.hwaddr=00:16:3e:.*).

When multiple filters are passed, they are added one on top of the other, selecting instances which satisfy them all. (Stack 'em, they all gotta pass πŸ’€)

πŸŽ€ Columns πŸŽ€

The -c option takes a comma separated list of arguments that control which instance attributes to output when displaying in table or csv format.

Column arguments are either pre-defined shorthand chars (see below), or (extended) config keys.

Commas between consecutive shorthand chars are optional. (slay, low effort)

Pre-defined column shorthand chars:

  • 4 β€” IPv4 address
  • 6 β€” IPv6 address
  • a β€” Architecture
  • b β€” Storage pool
  • c β€” Creation date
  • d β€” Description
  • D β€” disk usage
  • e β€” Project name
  • l β€” Last used date
  • m β€” Memory usage
  • M β€” Memory usage (%)
  • n β€” Name
  • N β€” Number of Processes
  • p β€” PID of the instance's init process
  • P β€” Profiles
  • s β€” State
  • S β€” Number of snapshots
  • t β€” Type (container or virtual-machine, ephemeral indicated if applicable)
  • u β€” CPU usage (in seconds)
  • L β€” Location of the instance (e.g. its cluster member)
  • f β€” Base Image Fingerprint (short)
  • F β€” Base Image Fingerprint (long)

Custom columns are defined with "[config:|devices:]key[:name][:maxWidth]":

  • KEY: The (extended) config or devices key to display. If [config:|devices:] is omitted then it defaults to config key.
  • NAME: Name to display in the column header. Defaults to the key if not specified or empty.
  • MAXWIDTH: Max width of the column (longer results are truncated). Defaults to -1 (unlimited). Use 0 to limit to the column header size.

πŸ’– OPTIONS πŸ’–

  • --all-projects[=false] β€” Display instances from all projects
  • -c, --columns="ns46tSL" β€” Columns``
  • --fast[=false] β€” Fast mode (same as --columns=nsacPt)
  • -f, --format="table" β€” Format `(csv|json|table|yaml|compact)```

🌈 OPTIONS INHERITED FROM PARENT COMMANDS 🌈

(these come from the parent command, not from lxc list itself β€” just so you know 🧚)

  • --debug[=false] β€” Show all debug messages
  • --force-local[=false] β€” Force using the local unix socket
  • -h, --help[=false] β€” Print help
  • --project="" β€” Override the source project``
  • -q, --quiet[=false] β€” Don't show progress information
  • --sub-commands[=false] β€” Use with help or --help to view sub-commands
  • -v, --verbose[=false] β€” Show all information messages
  • --version[=false] β€” Print version number

πŸ”₯ EXAMPLE πŸ”₯

lxc list -c nFs46,volatile.eth0.hwaddr:MAC,config:image.os,devices:eth0.parent:ETHP

Show instances using the "NAME", "BASE IMAGE", "STATE", "IPV4", "IPV6" and "MAC" columns. "BASE IMAGE", "MAC" and "IMAGE OS" are custom columns generated from instance configuration keys. "ETHP" is a custom column generated from a device key.

lxc list -c ns,user.comment:comment

List instances with their running state and user comment.


πŸ‘‘ SEE ALSO πŸ‘‘

lxc(1) β€” go read that one too, iykyk πŸ’œ


πŸ“œ HISTORY πŸ“œ

22-Aug-2026 Auto generated by spf13/cobra


okay that's the whole page, you ate that πŸ“ and for the record this was Auto generated by spf13/cobra, dated Aug 2026, living under LXD - Command line client(1) β€” mwah, go list some instances bestie πŸ’…βœ¨

πŸ“¦ where this page comes from