Ben Chuanlong Du's Blog

It is never too late to learn.

Tips on LXD

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

  1. LXD only works in Linux. It is not supported on macOS or Windows.

  2. LXD does not require a CPU which supports virtualization.

  3. Docker is a more user-friendly alternative to LXD containers and multipass is a more user-friendly alternative to LXD virtual machines. It is suggested that you use Docker/multipass instead of LXD.

Installation

sudo snap install lxd
gpasswd -a `id -un` lxd
newgrp lxd

Setup LXD

lxd init

Launch a container

lxc list
lxc launch ubuntu:22.04
lxc exec stirring-beagle -- ls -la
lxc exec -t stirring-beagle /bin/bash

Publish LXD Images

https://ubuntu.com/tutorials/create-custom-lxd-images

https://ubuntu.com/blog/publishing-lxd-images

https://medium.com/@tcij1013/lxc-lxd-cheetsheet-effb5389922d

https://github.com/lxc/lxd/issues/6805

LXDHub

References

Comments