Canonical has released multipass 1.0, a toolkit for deploying Ubuntu in virtual machines

Canonical Company presented first stable release of the toolkit multipass 1.0, designed to simplify the installation of various versions of Ubuntu in virtual machines running on Linux, Windows and macOS virtualization systems. Multipass allows a developer to run the desired version of Ubuntu in a virtual machine with one command without additional settings, for example, to experiment or test the operation of their application. Linux uses KVM to run a virtual machine, Windows uses Hyper-V, and macOS uses HyperKit on macOS. It is also possible to use VirtualBox to run virtual machines. The project code is written in C++ and spreads licensed under GPLv3. Prepared for a quick installation of multipass in Ubuntu snap package.

Multipass independently extracts the required operating system image and keeps it up to date. Cloud-init can be used for configuration. It is possible to mount external disk partitions in a virtual environment (multipass mount command), but it also provides means of transferring individual files between the host system and the virtual machine (multipass transfer). The user's home directory is automatically mounted in the virtual machine as ~/Home. Full integration of the installed virtual machine with the main desktop is supported (application icons, system menu and notifications are added).

An example session in multipass:

Search for available images:

$multipass find
Image Aliases Version Description
core core16 20190424 Ubuntu Core 16
core18 20190213 Ubuntu Core 18
16.04 xenial 20190628 Ubuntu 16.04 LTS
18.04 bionic,lts 20190627.1 Ubuntu 18.04 LTS
18.10 cosmic 20190628 Ubuntu 18.10
19.04 disco 20190628 Ubuntu 19.04
daily:19.10 devel,eoan 20190623 Ubuntu 19.10

We start the actual release of Ubuntu LTS in the VM:

$ multipass launch ubuntu
Launching dancing-chipmunk…
Downloading Ubuntu 18.04 LTS……….
Launched: dancing chipmunk

View the list of running VMs:

$multipass list
Name State IPv4 Release
dancing-chipmunk RUNNING 10.125.174.247 Ubuntu 18.04 LTS
live-naiad RUNNING 10.125.174.243 Ubuntu 18.04 LTS
snapcraft-asciinema STOPPED - Ubuntu Snapcraft builder for Core 18

Getting detailed information about the running VM

$ multipass info dancing-chipmunk
Name: dancing-chipmunk
State: RUNNING
IPv4: 10.125.174.247
Release: Ubuntu 18.04.1 LTS
Image hash: 19e9853d8267 (Ubuntu 18.04 LTS)
Load: 0.97 0.30 0.10
Disk usage: 1.1G out of 4.7G
Memory usage: 85.1M out of 985.4M

Connecting to a shell command in the VM

$ multipass shell dancing-chipmunk
Welcome to Ubuntu 18.04.1 LTS (GNU/Linux 4.15.0-42-generic x86_64)
#

Run the "lsb_release -a" command in the VM environment:

$ multipass exec dancing-chipmunk --lsb_release -a
No LSB Modules ARE Available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.1 LTS
Release: 18.04
Codename: bionic

Stop the VM:

$ multipass stop dancing-chipmunk

Remove VM:

$ multipass delete dancing-chipmunk

Name State IPv4 Release
snapcraft-asciinema STOPPED - Ubuntu Snapcraft builder for Core 18
dancing-chipmunk DELETED—Not Available

Clean up deleted VMs from disk

$multipass purge

Source: opennet.ru

Add a comment