Difference between ubuntu in linuxcontainers and official repositories (cloud/minimal)?

Hey folks. Poked around a bit but struggled to figure out the answer.
Is the difference between the Ubuntu templates in the images: (images.linuxcontainers.org) repository and the ubuntu: (cloud-images.ubuntu.com) repository that the images: build is a minimal build of Ubuntu Server, as opposed to the Ubuntu Cloud builds? If so, how are the images: ubuntu templates different from the ubuntu-minimal: (cloud-images.ubuntu.com/minimal) templates? I can see the distrobuilder yaml in the linuxcontainers.org builds but not sure for the minimal builds.

Paradox of choice has me wondering if there’s a quick answer for this. Thank you!

1 Like

Haha, yeah, there are a few options, basically:

  • ubuntu:20.04 => Full cloud image with cloud-init and a bunch of extra tools (snapd, htop, tmux …)
  • ubuntu-minimal:20.04 => Variant of the cloud image but with most of the user tooling and things like manpages removed, intended for scripted use cases
  • images:ubuntu/20.04 => Minimal Ubuntu, meant for actual users but very little additional package installed
  • images:ubuntu/20.04/cloud => Identical to above but cloud-init added

As far as sizes, it looks like:

  • images:ubuntu/20.04 => 103MB
  • images:ubuntu/20.04/cloud => 118MB
  • ubuntu-minimal:20.04 => 121.15MB
  • ubuntu:20.04 => 366MB
2 Likes

Thanks for the prompt and thorough reply!

All makes sense—the thing that was tripping me up most of all was ubuntu-minimal versus the cloud-init variant in the images: repository. I do eventually try to move my containers to being provisioned via cloud-init but it sounds like there is no harm in sticking with the images: template since I pop in and do user-y things every now and again—especially since the sizes are basically the exact same.

Thanks again.

My colleague ran into some issues bootstrapping a kubernetes cluster and it took me a while to figure out why it worked for me but not for him. The reason is a difference in kernel package between the ubuntu 20.04 images from the ubuntu and images repository.

I personally use the https://images.linuxcontainers.org for everything. Those ubuntu VM images come with the linux-virtual meta package for the kernel. The VM images from images.ubuntu.com come with linux-kvm. Linux-kvm has fewer modules including some required ones for k8s.

On a images:ubuntu/20.04:

root@light-reptile:~# uname -r
5.4.0-84-generic
root@light-reptile:~# modprobe bpfilter
root@light-reptile:~# lsmod | grep bpfilter
bpfilter               32768  0

On a ubuntu:20.04

root@calm-manatee:~# uname -r
5.4.0-1046-kvm
root@calm-manatee:~# modprobe bpfilter
modprobe: FATAL: Module bpfilter not found in directory /lib/modules/5.4.0-1046-kvm