How to Quickly Set Up Lightweight Ubuntu VMs with Multipass – A Complete Guide
This article introduces the free, lightweight Multipass tool, walks through its installation on Windows, Linux and macOS, demonstrates creating, managing, and automating Ubuntu virtual machines with command‑line operations, and highlights its strengths and limitation to Ubuntu images only.
For IT professionals, VMware is widely used but costly and less friendly for beginners; this article introduces Multipass, a free, lightweight virtual machine tool from Canonical.
Multipass Overview
Multipass is a lightweight command‑line VM manager supporting Linux, Windows, and macOS, using the appropriate virtualization technology on each OS and consuming minimal resources.
Installation
Download the installer for your operating system from https://multipass.run/install.
After installation, verify the version:
$ multipass versionUsing Multipass
Create an Ubuntu VM
List available Ubuntu images: $ multipass find Launch a container named dg: $ multipass launch --name dg Check the VM’s description:
$ multipass exec dg -- lsb_release -dManage VMs
List all VMs: $ multipass list Show detailed information: $ multipass info --all Enter the VM shell: $ multipass shell dg Pause and start the VM:
# pause
$ multipass stop dg
# start
$ multipass start dgDelete and purge the VM:
# delete
$ multipass delete dg
# purge
$ multipass purge dgAutomation with cloud‑init
Use --cloud-init to run initialization scripts on first launch. Example config.yaml installs Node.js and the LeanCloud CLI:
#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.debConclusion
Multipass enables rapid provisioning of Ubuntu virtual machines for testing, small database clusters, or other experiments, though it only supports Ubuntu images.
Related Links
Official site: https://multipass.run/
Documentation: https://multipass.run/docs/
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Java High-Performance Architecture
Sharing Java development articles and resources, including SSM architecture and the Spring ecosystem (Spring Boot, Spring Cloud, MyBatis, Dubbo, Docker), Zookeeper, Redis, architecture design, microservices, message queues, Git, etc.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
