Multipass [Link] is not a Hypervisor, it is a tool to quickly and easily start a fresh Ubuntu VMs (Virtual Machines) using the Native hypervisor of the OS (Operations System) or LXC in on Linux (very much recommended).

This is an incredibly easy tool for lunching disposable instances for developments and tests but not recommended to be used in production except for non-mission critical work loads.

Find out more in this post Snap vs Docker vs Multipass [Link].


INSTALLING

sudo apt update
sudo apt install snapd
sudo snap install multipass --classic

USING

Searching for Images

multipass find

Guess what? There is only images of Ubuntu. What a surprise!

Launching Instance –  Automatically downloads and runs.

multipass launch lts --name web-server
multipass launch jammy --name ftp-server
multipass launch 20.04 --name db-server

  • Optional Parameters
    • –cpu 2
    • –mem 2G
    • –disk 20G
    • –mount /Host_Pat­h:/Guest_Path

Gathering Information

multipass list
multipass info

Executing Commands and Getting Shells

multipass exec web-server -- lsb_release -a
multipass exec ftp-server -- cat /etc/os-release
multipass shell db-server

Managing Instances

Operating

multipass stop web-server ftp-server
multipass start web-server
multipass delete web-server db-server
multipass purge

Modifying

multipass stop ftp-server
multipass set local.ftp-server.cpus=4
multipass set local.ftp-server.disk=50G
multipass set local.ftp-server.memory=4G

Backups and Snapshots

multipass snapshot ftp-server
multipass list --snapshots
multipass restore ftp-server.snapshot1
multipass delete ftp-server.snapshot1

Creating Aliases

Alias is a great feature that allow running commands inside a guest as if they were on the host.

multipass alias ftp-server:htop
htop
multipass aliases
multipass unalias htop
multipass unalias --all

Uninstalling Multipass

sudo snap remove multipass

Good luck with your projects!