Previous page

Next page

Locate page in Contents

Print this page

Configuring Disk I/O Bandwidth

In Virtuozzo, you can configure the bandwidth virtual machines and Containers are allowed to use for their disk input and output (I/O) operations. Limiting the disk I/O bandwidth can help you prevent the situations when high disk activities in one virtual machine or Container (generated, for example, by transferring huge amounts of data to/from the virtual machine or Container) can slow down the performance of other virtual machines and Containers on the host.

By default, the I/O bandwidth limit for all newly created virtual machines and Containers is set to 0, which means that no limits are applied to any virtual machines and Containers. To limit the disk I/O bandwidth for a virtual machine or Container, you can use the --iolimit option of the prlctl set command. For example, the following command sets the I/O bandwidth limit for the MyVM virtual machine to 10 megabytes per second (MB/s):

# prlctl set MyVM --iolimit 10

Set up iolimit: 10485760

The VM has been successfully configured.

To set the limit for a Container, just specify its ID instead of the virtual machine name, for example:

# prlctl set 101 --iolimit 10

Set up iolimit: 10485760

Saved parameters for Container 101

By default, the limit is set in megabytes per second. However, you can use the following suffixes to use other measurement units:

  • G: sets the limit in gigabytes per second (1G).
  • K: sets the limit in kilobytes per second (10K).
  • B: sets the limit in bytes per second (10B).

Note: In the current version of Virtuozzo, the maximum I/O bandwidth limit you can set for a virtual machine or Container is 2 GB per second.

To check that the I/O speed limit has been successfully applied to the MyVM virtual machine and Container 101, use the prlctl list command:

# prlctl list MyVM -o iolimit

110485760

# prlctl list 101 -o iolimit

IOLIMIT

10485760

At any time, you can remove the I/O bandwidth limit set for the MyVM virtual machine and Container 101 by running these commands:

# prlctl set MyVM --iolimit 0

Set up iolimit: 0

The VM has been successfully configured.

# prlctl set 101 --iolimit 0

Set up iolimit: 0

Saved parameters for Container 101