Updated attachment logic

This commit is contained in:
Jeff Bonhag 2020-07-02 13:22:09 -04:00
parent 3cb01415e4
commit 8c90eb7b05
No known key found for this signature in database
GPG Key ID: 32966F3FB5AC1129
3 changed files with 26 additions and 12 deletions

View File

@ -86,9 +86,10 @@ Vagrant.configure("2") do |config|
end
```
Note: VirtualBox only allows for up to 30 disks to be attached to a given SATA Controller,
and this number includes the primary disk! Attempting to configure more than 30 will
result in a Vagrant error.
Note: VirtualBox has a hard limit on the number of disks that can be attached
to a given storage controller, which is defined by the controller type.
Attempting to configure more disks than are supported by the primary
controller will result in a Vagrant error.
### Attaching optical drives
@ -106,8 +107,8 @@ Vagrant.configure("2") do |config|
end
```
Note: VirtualBox only allows for up to 4 optical drives to be attached to a
given IDE controller.
As with hard disks, configuring more disks than are supported by your VM's
storage controller arrangement will result in a Vagrant error.
### Removing Disks

View File

@ -21,10 +21,21 @@ you should see a list of disks attached to your guest.
## How many disks can I attach?
Vagrant attaches all new disks defined to a guests SATA Controller. As of VirtualBox 6.1.x,
SATA Controllers can only support up to **30 disks** per guest. Therefore if you try
to define and attach more than 30, it will result in an error. This number _includes_
the primary disk for the guest.
Vagrant attaches all new disks defined to guest's primary controller. As of
VirtualBox 6.1.x, storage controllers have the following limits to the number
of disks that are supported per guest:
- IDE Controllers: 4
- SATA Controllers: 30
- SCSI Controllers: 16
Therefore if your primary disk is attached to a SATA Controller and you try to
define and attach more than 30, it will result in an error. This number
_includes_ the primary disk for the guest.
DVD attachments are subject to the same limits. Optical disk attachments will
be attached to the storage controller with the highest boot priority (usually
the IDE controller).
## Resizing VMDK format disks

View File

@ -34,9 +34,11 @@ to be applied.
When new disks are defined to be attached to a guest, Vagrant will attach
disks to a particular storage controller based on the type of disk configured:
- For the `:disk` type, Vagrant will attach the disk to a guest's SATA
controller. It will also create the disk if necessary.
- For the `:dvd` type, Vagrant will attach the disk to a guest's IDE
- For the `:disk` type, Vagrant will use the storage controller containing the
boot disk. It will also create the disk if necessary.
- For the `:dvd` type, Vagrant will attach the disk to the storage controller
that comes earliest in the machine's boot order. For example, if a VM has a
SATA controller and an IDE controller, the disk will be attached to the IDE
controller.
Vagrant will not be able to configure disks of a given type if the associated