Score:0

Manually download multipass VM images

cn flag

Not sure if multipass run VMs locally or in the cloud, but if it is running locally is must download e.g. qemu2 images first. Can one download these image manually? Is there a simple URL to e.g. Ubuntu 20.04 LTS?

(Just wanna test something in 20.04 and wanna spin up a VM quickly on my current running KVM/QEMU hypervisor and it would really be easy if I could get my hands on a pre-made Ubuntu qemu2 image...I'm guessing one exist in the multipass universe. Don't wanna install multipass on my server (yet))

MrCalvin avatar
cn flag
Maybe here? [https://cdimage.ubuntu.com/ubuntu-core/20/stable/manual/](https://cdimage.ubuntu.com/ubuntu-core/20/stable/manual/)
Score:0
sv flag

The other answer here encourages the OP to just use multipass. That may be good advice but does not answer the OP's question. There may be valid reasons to not use multipass but still want to get the same image.

Looking at the code you can see it uses these URLs:

For Ubuntu official image repos it seems to go through a couple of levels of meta data level1 and level2 but then will end up using something like this for 22.04 x86 right now. If you fetch that url the server will direct you to a simpler url. The meta data files are not visible by normal browsing but the files you end up at are.

I did not grock all of that code but one simple method to find the image you want is to: (path below is specific to a Linux host, adjust for others)

  • use multipass to launch what you want
  • sudo cat /var/snap/multipass/common/cache/multipassd/vault/multipassd-image-records.json
  • Copy the sha256 value and then search for that in the level2 meta data I mentioned above.
Score:0
in flag

Multipass VMs can be run in the cloud and locally. If you would like to have the 20.04 LTS running on your machine, you can do this:

sudo snap install multipass
multipass launch --name test

That will download the necessary components and start a VM named test running 20.04 LTS. You can test that it's working by running a simple command, like "what version are you?":

multipass exec test -- lsb_release -a

If this is something you might use in a production setting, you'll want to familiarise yourself with Cloud-init, as there's a remarkable amount of utility with this tool.

MrCalvin avatar
cn flag
I don't wanna install multipass on my server.. I'm sure the above command download an image, just need the URl? Then I'll spin up the VM in my existing hypervisor environment (libvirt)....I like to have 100% control of what's going on.
in flag
There's more to Multipass than it being just a VM engine. That said, if you would like a raw Ubuntu Server image that is generally aimed at cloud-based environments, you can find [Ubuntu certified images for 20.04 across several architectures here](http://cloud-images.ubuntu.com/focal/current/).
MrCalvin avatar
cn flag
Thanks. that's perfect for my need :-) Just out of curiosity, is Multipess using these images too?
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.