Operations 6 min read

Getting Started with Multipass: Installing, Creating, and Managing Ubuntu Virtual Machines

This tutorial introduces Multipass, a lightweight cross‑platform VM manager, and walks through downloading, installing, checking the version, listing available Ubuntu images, launching a VM, inspecting and controlling it, and automating setup with cloud‑init configuration.

Code Ape Tech Column
Code Ape Tech Column
Code Ape Tech Column
Getting Started with Multipass: Installing, Creating, and Managing Ubuntu Virtual Machines

Hello everyone, I'm Chen. When it comes to virtual machine tools, most people think of VMware, which is powerful but requires a paid license.

Multipass is a lightweight, cross‑platform command‑line tool for managing VMs on Linux, Windows, and macOS.

First, download and install Multipass for your operating system (the example uses Windows).

After installation, check the installed version:

$ multipass version

Find the available Ubuntu images:

$ multipass find

Launch a new Ubuntu container named dg :

$ multipass launch --name dg

Verify the VM is running and view its IP address:

Name    State    IPv4          Image
DG      Running  192.168.24.5  Ubuntu 18.04 LTS

Get detailed information about the VM:

$ multipass info --all
Name:    dg
State:   Running
IPv4:    192.168.24.5
Release: Ubuntu 18.04.4 LTS
Image hash: fe3030933742 (Ubuntu 18.04 LTS)
Load:    0.00 0.00 0.00
Disk usage: 1.5G out of 4.7G
Memory usage: 112.1M out of 985.7M

Enter the VM shell:

$ multipass shell dg

Pause or restart the VM:

# Pause
$ multipass stop dg
# Start
$ multipass start dg

Delete and purge the VM:

# Delete
$ multipass delete dg
# Purge
$ multipass purge dg

Automate VM initialization with --cloud-init and a YAML config file:

$ multipass launch --name ubuntu --cloud-init config.yaml

Example config.yaml content:

#cloud-config

runcmd:
  - curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
  - sudo apt-get install -y nodejs
  - wget https://releases.leanapp.cn/leancloud/lean-cli/releases/download/v0.21.0/lean-cli-x64.deb
  - sudo dpkg -i lean-cli-x64.deb

Multipass is convenient for quick Linux experiments and can be used to set up small database clusters locally.

The only limitation is that Multipass currently supports only Ubuntu images, as it is developed by Canonical.

CLIAutomationdevopsVirtual MachineUbuntuMultipass
Code Ape Tech Column
Written by

Code Ape Tech Column

Former Ant Group P8 engineer, pure technologist, sharing full‑stack Java, job interview and career advice through a column. Site: java-family.cn

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.