Show subnet in use on remote lxd host in output of lxc remote list

Is there a hidden option that we can use to reveal, in the output of lxc remote list, the subnet in use on remote LXD host?

Currently, I keep an Excel spreadsheet to help keep track of these subnets. It would be good to get a live feed of such info.

EDIT: Moving this to LXD; should have done that in the first place.

Not sure what you mean. If you want the list of addresses that LXD is listening on on a remote server, lxc info will have that in the addresses section.

If you want the list of network interfaces on the LXD server, lxc network list will show you a list. Those manages by LXD will show their IPv4/IPv6 addresses there. Those not managed by LXD you can query with lxc network info NAME and you’ll get the details then.

Hi @stgraber

Being a lazy sysadmin, it would be good to see the subnet in use on the remote lxdbr0 interface in the output of lxd remote list. For instance, say I have 3 remote LXD hosts. Instead of logging into each of them to determine this, it would be good to have something like below (see the last column of what I’m after):

lxc remote list
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
|     NAME           |                   URL                    |   PROTOCOL    |  AUTH TYPE  | PUBLIC | STATIC | GLOBAL | SUBNET      |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| lxdhost1 (current) | https://lxd1.domain.com:8443             | lxd           | tls         | NO     | NO     | NO     | 10.1.0.0/24 |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| lxdhost2           | https://lxd2.domain.com:8443             | lxd           | tls         | NO     | NO     | NO     | 10.2.0.0/24 |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| lxdhost3           | https://lxd3.domain.com:8443             | lxd           | tls         | NO     | NO     | NO     | 10.3.0.0/24 |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| images             | https://images.linuxcontainers.org       | simplestreams | none        | YES    | NO     | NO     | none        |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| local              | unix://                                  | lxd           | file access | NO     | YES    | NO     | 10.0.0.0/24 |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| ubuntu             | https://cloud-images.ubuntu.com/releases | simplestreams | none        | YES    | YES    | NO     | none        |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+
| ubuntu-daily       | https://cloud-images.ubuntu.com/daily    | simplestreams | none        | YES    | YES    | NO     | none        |
+--------------------+------------------------------------------+---------------+-------------+--------+--------+--------+-------------+

All this to promote sheer laziness. But I have a feeling I’m not alone.

Is this doable?

–Cheers.

Ah yeah, no, we’re not going to do that.
You can have MANY networks, I have production deployments with over 50 bridges on some systems. Also, lxc remote list is a local-only command. It doesn’t make any API calls whereas this would require a whole bunch of them.

I’m afraid you’re going to have to stick to lxc network list remote: