Enabling CPU and RAM hot plug per domain
To allow self-service users to add more CPU and RAM resources to virtual machines at run time, you can enable CPU and RAM hot plug for a particular domain. In domains that have this feature disabled, users will need to stop a virtual machine first, to be able to change its flavor. By default, CPU and RAM hot plug is disabled for all domains.
To enable CPU and RAM hot plug for a domain
Admin panel
- On the Projects and users screen, click the required domain.
- Switch to the Settings > CPU and RAM hot plug screen, and then enable CPU and RAM hot plug.
Command-line interface
Use the following command:
vinfra domain properties create --key <key> --data <data> [--access <access>] <domain>
--key <key>
- Key name
--data <data>
- Property sheet. Should be a valid JSON object.
--access <access>
-
Access type:
pub
: grant read access to all users (authentication is not required)auth
: grant read access to authenticated usersdomain
: grant read access to domain users
-
The superadmin and domain admin have write access.
<domain>
- Domain name or ID
For example, to create the property allow_live_resize
that enables CPU and RAM hot plug for virtual machines within the domain mydomain
, run:
# vinfra domain properties create --key allow_live_resize mydomain --data '{"enabled":true}'
The created property will appear in the vinfra domain properties keys list
output:
# vinfra domain properties keys list +----------+---------------------+ | domain | keys | +----------+---------------------+ | mydomain | - allow_live_resize | | Default | - allow_live_resize | +----------+---------------------+
To disable CPU and RAM hot plug for a domain
Admin panel
- On the Projects and users screen, click the required domain.
- Switch to the Settings > CPU and RAM hot plug screen, and then disable CPU and RAM hot plug.
Command-line interface
Use the following command:
vinfra domain properties update --key <key> --data <data> [--access <access>] <domain>
--key <key>
- Key name
--data <data>
- Property sheet. Should be a valid JSON object.
--access <access>
-
Access type:
pub
: grant read access to all users (authentication is not required)auth
: grant read access to authenticated usersdomain
: grant read access to domain users
-
The superadmin and domain admin have write access.
<domain>
- Domain name or ID
For example, to change the property allow_live_resize
to disable CPU and RAM hot plug for virtual machines within the domain mydomain
, run:
# vinfra domain properties update --key allow_live_resize mydomain \ --data '{"enabled": false}'