How to create an instance

See also: launch, list, exec, shell, info.

To create an instance with Multipass, simply execute:

$ multipass launch
Launched: keen-yak

As you can see from the output, this has launched a new Ubuntu instance, which has been randomly named keen-yak.

If you want to be more specific about the kind of instance you want, you can do so by passing options. For example, the code below launches an instance named myVM with 2GB of memory, 10GB of disk, 2 CPU cores, running Ubuntu 21.10 (“Impish Indri”).

$ multipass launch --name myVM --mem 2G --disk 10G --cpus 2 impish
Launched: myVM

At this point, if you’d like to inspect the results, you can run:

$ multipass list
Name                    State             IPv4             Release
keen-yak                RUNNING     Ubuntu 20.04 LTS
myVM                    RUNNING     Ubuntu 21.10

Or you can ask for an extended status report:

$ multipass info keen-yak
Name:           keen-yak
State:          RUNNING
Release:        Ubuntu 18.04.1 LTS
Image hash:     d53116c67a41 (Ubuntu 18.04 LTS)
Load:           0.00 0.12 0.18
Disk usage:     1.1G out of 4.7G
Memory usage:   71.6M out of 985.4M

Now, you can start doing things in the new instance. To execute commands directly, use the exec command.

$ multipass exec keen-yak <command>

Otherwise, to open a shell inside the instance, use shell.

$ multipass shell keen-yak
Welcome to Ubuntu 20.04.4 LTS (GNU/Linux 5.4.0-104-generic x86_64)

Last updated a day ago.