123 lines
4.0 KiB
Groff
123 lines
4.0 KiB
Groff
.nh
|
|
.TH podman-machine-set 1
|
|
.SH NAME
|
|
podman-machine-set \- Set a virtual machine setting
|
|
|
|
.SH SYNOPSIS
|
|
\fBpodman machine set\fP [\fIoptions\fP] [\fIname\fP]
|
|
|
|
.SH DESCRIPTION
|
|
Change a machine setting.
|
|
|
|
.PP
|
|
The default machine name is \fBpodman-machine-default\fR\&. If a machine name is not specified as an argument,
|
|
then the settings will be applied to \fBpodman-machine-default\fR\&.
|
|
|
|
.PP
|
|
Rootless only.
|
|
|
|
.PP
|
|
Default Podman machine settings can be set via the [machine] section in the containers.conf(5) file.
|
|
|
|
.SH OPTIONS
|
|
.SS \fB--cpus\fP=\fInumber\fP
|
|
Number of CPUs.
|
|
Only supported for QEMU machines.
|
|
|
|
.SS \fB--disk-size\fP=\fInumber\fP
|
|
Size of the disk for the guest VM in GB.
|
|
Can only be increased. Only supported for QEMU machines.
|
|
|
|
.SS \fB--help\fP
|
|
Print usage statement.
|
|
|
|
.SS \fB--memory\fP, \fB-m\fP=\fInumber\fP
|
|
Memory (in MB).
|
|
Only supported for QEMU machines.
|
|
|
|
.SS \fB--rootful\fP
|
|
Whether this machine prefers rootful (\fBtrue\fR) or rootless (\fBfalse\fR)
|
|
container execution. This option updates the current podman
|
|
remote connection default if it is currently pointing at the specified
|
|
machine name (or \fBpodman-machine-default\fR if no name is specified).
|
|
|
|
.PP
|
|
Unlike [\fBpodman system connection default\fP]
|
|
this option makes the API socket, if available, forward to the rootful/rootless
|
|
socket in the VM.
|
|
|
|
.PP
|
|
Note that changing this option means that all the existing containers/images/volumes, etc...
|
|
are no longer visible with the default connection/socket. This is because the root and rootless
|
|
users in the VM are completely separated and do not share any storage. The data however is not
|
|
lost and you can always change this option back or use the other connection to access it.
|
|
|
|
.SS \fB--usb\fP=\fIbus=number,devnum=number\fP or \fIvendor=hexadecimal,product=hexadecimal\fP or \fI""\fP
|
|
Assign a USB device from the host to the VM.
|
|
Only supported for QEMU Machines.
|
|
|
|
.PP
|
|
The device needs to be present when the VM starts.
|
|
The device needs to have proper permissions in order to be assign to podman machine.
|
|
|
|
.PP
|
|
Use an empty string to remove all previously set USB devices.
|
|
|
|
.PP
|
|
Note that using bus and device number are simpler but the values can change every boot or when the
|
|
device is unplugged. Using vendor and product might lead to collision in the case of multiple
|
|
devices with the same vendor product value, the first available device is assigned.
|
|
|
|
.SS \fB--user-mode-networking\fP
|
|
Indicates that this machine relays traffic from the guest through a user-space
|
|
process running on the host. In some VPN configurations the VPN may drop
|
|
traffic from alternate network interfaces, including VM network devices. By
|
|
enabling user-mode networking (a setting of \fBtrue\fR), VPNs observe all
|
|
podman machine traffic as coming from the host, bypassing the problem.
|
|
|
|
.PP
|
|
When the qemu backend is used (Linux, Mac), user-mode networking is
|
|
mandatory and the only allowed value is \fBtrue\fR\&. In contrast, The Windows/WSL
|
|
backend defaults to \fBfalse\fR, and follows the standard WSL network setup.
|
|
Changing this setting to \fBtrue\fR on Windows/WSL informs Podman to replace
|
|
the WSL networking setup on start of this machine instance with a user-mode
|
|
networking distribution. Since WSL shares the same kernel across
|
|
distributions, all other running distributions reuses this network.
|
|
Likewise, when the last machine instance with a \fBtrue\fR setting stops, the
|
|
original networking setup is restored.
|
|
|
|
.SH EXAMPLES
|
|
To switch the default Podman machine from rootless to rootful:
|
|
|
|
.EX
|
|
$ podman machine set --rootful
|
|
.EE
|
|
|
|
.PP
|
|
or more explicitly set with value true.
|
|
|
|
.EX
|
|
$ podman machine set --rootful=true
|
|
.EE
|
|
|
|
.PP
|
|
Switch the default Podman machine from rootful to rootless.
|
|
|
|
.EX
|
|
$ podman machine set --rootful=false
|
|
.EE
|
|
|
|
.PP
|
|
Switch the specified Podman machine from rootless to rootful.
|
|
|
|
.EX
|
|
$ podman machine set --rootful myvm
|
|
.EE
|
|
|
|
.SH SEE ALSO
|
|
\fBpodman(1)\fP, \fBpodman-machine(1)\fP, \fBcontainers.conf(5)\fP
|
|
|
|
.SH HISTORY
|
|
February 2022, Originally compiled by Jason Greene jason.greene@redhat.com
|
|
\[la]mailto:jason.greene@redhat.com\[ra]
|