3 ms·
> Docker / kubernetes is eating it up Is LXD's purpose the same as Docker/Kubernetes? I use both LXD and Docker and to me they are tools that use the same tech
by MrPowerGamerBR 3y ago
> Docker / kubernetes is eating it up
Is LXD's purpose the same as Docker/Kubernetes? I use both LXD and Docker and to me they are tools that use the same technology (containerzation) but for different purposes. Docker is for stateless containers, used to containerize services. LXD is for stateful containers, used to containerize operating systems. LXD can also run VMs while Docker can't.
I think about LXD as a sort of Proxmox alternative (because you can manage LXC containers and VMs with it) instead of a Docker/Kubernetes alternative. In fact, I actually have migrated my systems from Proxmox to Ubuntu Server with Docker, for stateless applications, and LXD, for when I need to containerize an entire OS or VMs for my friends.
- nine_k 3y agoSince Linux containers are just namespace tricks, a kind of glorified chroot, what does it mean that you run VMs from within containers? Sincerely curious'
- justinclift 3y agohttps://ubuntu.com/blog/lxd-virtual-machines-an-overview https://ubuntu.com/blog/lxd-virtual-machines-an-overview
- veidr 3y agoI don't think OP means running VM from within containers (although, who knows, I mean I guess you could). LXD provides a management layer that treats containers and VMs (libvirt/KVM/QEMU VMs) mostly the same. So commands like this work on both containers and VMs: lxc start fedora-desktop lxc mv pi-hole other-machine:pi-hole etc
- unixhero 3y agoYes they are. And they work very well and can be used in production
- re-thc 3y ago> Is LXD's purpose the same as Docker/Kubernetes? It did occupy the same space including Proxmox. Back then KVM, Proxmox, VMWare, OpenVZ, LXD, etc were all ways of virtualization. Whilst it's not exactly the same purpose most companies have or have been shifting to docker and kubernetes and in the cloud vs running their own VM infrastructure. > Docker is for stateless containers Tell that to people that run databases with docker and kubernetes. It is a thing and even commercial products are built that way.
- MrPowerGamerBR 3y ago> Tell that to people that run databases with docker and kubernetes To be honest my original message wasn't clear enough: What I wanted to mean is that I like using Docker when I have a container image ready to run, "stateless" in the meaning that the image itself is unmodifiable and any changes to the image will be lost after a restart. (This doesn't include bind mounts, and stuff like that)
- veidr 3y agoExactly, we migrated to LXD from Proxmox for stateful containers for various servers (DNS, Zulip, Mastodon) as well as user desktops (e.g. Ubuntu Desktop, Fedora, etc). LXD is nice because it has a nice management layer. It is really easy to migrate an instance (container or VM) and its state from one physical machine to another on the LAN, even if you don't want to bother with setting up an actual cluster.
- MrPowerGamerBR 3y agoI think that LXD as a Proxmox alternative is a very underrated idea to be honest. Don't get me wrong, Proxmox is a pretty good piece of software, but if your workload isn't tailored to VMs + you have private links between your clusters + you have shared storage, you end up adding way too much complexity to your stack even tho you aren't using the real useful features that Proxmox provides. So if you are in the "I just want to run my services" crowd, an Ubuntu Server (or any other distro, really) running Docker on baremetal + LXD for anything that can't run on Docker is way simpler to manage. Especially because running Docker on Proxmox is not fun (too cumbersome to run it within a LXC container + ZFS, running a big fat VM with Docker defeats the point since you can't backup individual containers with Proxmox anymore, and running Docker on the hypervisor is a big no-no) At the end of the day, nothing in Proxmox has a special magic sauce that makes it tick, and sometimes that complexity may be super cumbersome when you just want to run some dang Docker containers for your swifty new app. https://mrpowergamerbr.com/us/blog/2022-11-20-proxmox-isnt-for-you/ https://mrpowergamerbr.com/us/blog/2022-11-20-proxmox-isnt-f...
- laxis96 3y agoPlease note that Docker and LXC (and LXD by extension) are essentially the same technology packaged differently, with different yet overlapping use cases; in fact, early Docker Engine was based on LXC before they switched to containerd. Therefore I don't think there is anything that can run on LXC/LXD but not on Docker (and vice versa); it's more a matter of preference, whether you want a long-lived persistent virtual system (LXC/LXD) or ephemeral single-application containers with optional persistence (Docker). Still, nothing stops you from using LXC/LXD for ephemeral containers and Docker for long-lived systems, but you'd be using the non-optimal tool.
- solarkraft 3y agoHey, I'm looking for a Proxmox alternative! But how do I use LXD on Debian without Snap?