Creating linked clones
Now, with the base VMs prepared, let's create linked clones for the rest of the lab's infrastructure:
- On your LabHost, open Command Prompt.
- Change your current directory to
C:\CPBook\CPLab\Scripts
. - To see what the script is doing, I recommend opening it in a text editor, such as Notepad on Windows. This script will create linked clones of our base VMs, attach additional network interfaces, when necessary, and connect them to the corresponding network segments.
You have an option of either executing the clonevms.bat
script or copying and pasting the code contained in it into the CMD.
The following is an excerpt from the batch file demonstrating its operation. Note that we must use the CLI or a batch file to accomplish the cloning process, since the Oracle VirtualBox GUI allows the creation of VMs with a maximum of four network interfaces. The CLI options allow the creation of up to eight:
SET PATH=%PATH%;C:\Program Files...