5 ms·
I ran LXD for about a year in my home lab. Unfortunately, the easiest way to get it running is by installing Snap; which I didn't do. Instead I ran it on Alpine
by discardedrefuse 4y ago
I ran LXD for about a year in my home lab. Unfortunately, the easiest way to get it running is by installing Snap; which I didn't do. Instead I ran it on Alpine Edge (one of the few distros that actually has it in their package manager). LXD kept breaking after system updates and I got tired of troubleshooting. I suppose that's just part of the perils of running bleeding edge.
When LXD was running, I found that it feels like something between a VM and OCI container. In the whole pets vs cattle analogy, LXD containers definitely feel more like pets.
On the host, concepts are similar to OCI containers (networking, macvlan, port mapping, etc). I like its approach to building up containers with several commands instead of one long command. You can add and remove ports, volumes, and even GPUs to running containers. It doesn't have compose files, I just used bash scripts to create reproducible containers.
Inside the LXD container is where things get different. You're containerizing a whole OS, not an application. So you end up administering your container like a VM. You jump inside it, update its packages, install whatever application and dependencies you need. It doesn't work like a glorified package manager (which is how most homelabbers use Docker). As a long time VM user I actually prefer installing things myself, but I can see this turning away many people in the selfhosting community.
I liked LXD and would've kept using it if it weren't so intimately linked to Snap. Last month it failed to start my containers after a system update...again. So I moved that box over to Rocky with Podman containers running as SystemD units. I do kinda miss having fast, throwaway OSes on that server for experiments (sometimes its nice to have pets).
- leetnewb 4y agoSomeone packages it for opensuse. It has been stable for me on tumbleweed for a couple of years.
- discardedrefuse 4y agoThanks for the info. Never used OpenSuse, but next time my curiosity swings back around to LXD I'll check it out!
- leetnewb 4y agoIn the off chance you remember this conversation, the package does not require attr (even though lxd does), so you need to zypper in attr to get lxd running if another dependency didn't pull it.
- vladvasiliu 4y agoI've been using it in my homelab for a while on Arch with ZFS. Never had any issues with upgrades. However, I once wanted to rename my zpool. Boy was I up for a world of hurt. In the end, I just reinitialized everything (the VMs themselves were easy to get back up).
- pxc 4y ago> Unfortunately, the easiest way to get it running is by installing Snap; which I didn't do. Instead I ran it on Alpine Edge (one of the few distros that actually has it in their package manager). Enabling LXD is a one-liner on NixOS: virtualisation.lxd.enable = true; LXC and LXD are a somewhat common approach for NixOS users who want to quickly try something out in the environment of a traditional distro. :)
- vngzs 4y agoI use LXD like this on NixOS. It's great for Steam, which works best on Arch Linux.
- kwk1 4y ago> Unfortunately, the easiest way to get it running is by installing Snap; The Debian package for LXD just entered the archive about 2 weeks ago: https://tracker.debian.org/news/1361535/accepted-lxd-500-1-source-amd64-into-unstable/ https://tracker.debian.org/news/1361535/accepted-lxd-500-1-s... This means the next Debian release will make for stable LXD hosts without needing snap.
- discardedrefuse 4y agoThis is most excellent news!!!
- zekrioca 4y agoFinally!
- intelVISA 4y agoI really love LXD/LXC conceptually but I always found it broke in mysterious ways is there a suggested base distro for imbeciles like me? I end up retreating back to Podman as well.
- discardedrefuse 4y agoAccording to other comments OpenSuse and Arch have it stable now and the next release of Debian will have it.
- deleted 4y ago[deleted]