This post will go over getting a ThousandEyes lab built out. To see all the posts in this series expand the box below.
- Part 1 – The What and the Why
- Part 2 – Lab build <–You Are Here
- Part 3 – Enterprise and Endpoint Agent Installs
- Part 4.1 – SNMP Monitoring
- Part 4.2 Scenarios and Test Types
- Part 4.3.1 Scenario 1 – Enterprise agent to agent test configuration
- Part 4.3.2 Scenario 2 – Enterprise DNS test configuration
- Part 4.3.3 Scenario 3 – Enterprise and Endpoint HTTP test configuration (Coming soon)
- Part 4.3.4 Scenario 4 – Enterprise Page Load test configuration (Coming less soon)
- Part 4.3.5 Scenario 5 – Enterprise Transaction test configuration and Endpoint Agent Browser Settings (Coming more less soon)
- Part 4.4+ – Details TBD
There are some behind-the-scenes posts that go into more detail on how and why I took the approach that I did. Those can be found here:
- Behind the Scenes – The Lab Build
- Ok, there’s only one so far, but I plan to add more where it makes sense.
Lab Build
Topology
I’ve built out this lab using VMware Workstation and Cisco Modeling Labs to simulate a network for ThousandEyes to monitor.
The lab is broken down into four types of sites, Client, ISP, Public, and External. There are two Client sites, each consisting of two routers and two Ubuntu instances. The routers are running BGP, and have SNMP enabled. The first Ubuntu instance is only running a ThousandEyes agent, and the other instance is running a ThousandEyes agent and an Apache webserver.
The ISP networks are routers running BGP interconnecting all the other sites. I have SNMP enabled on them just to show what ThousandEyes can do with SNMP monitoring. Normally isn’t going to be accessible on ISP devices.
The Public zone is also running BGP and has an Ubuntu instance that is running DNS for the entire CML.LAB network.
The External site is used to bridge the lab environment to the network outside CML. It has a static route out to the LAN gateway that is redistributed into BGP, and a static IP assigned on the LAN. For traffic leaving the LAN, it has NAT configured. This should reduce the configuration needs on the LAN side. A static route can be added to the LAN gateway to send traffic to the External router, or static routes can be added to the individual devices that will connect to the lab network.
In addition to the CML lab, three additional devices will be deployed, an Ubuntu Server running Docker for ThousandEyes Enterprise Agents, a Windows 10 VM running the ThousandEyes Endpoint Agent, and a Raspberry Pi running the ThousandEyes Enterprise Agent.
This table breaks down the resources assigned to each node and the total amount of resources. The CML VM will need to have enough assigned to it to allow the nodes inside it to run.
The Windows and Ubuntu Docker nodes will sit outside CML, as VMs in VMware Workstation. There will also be a Raspberry Pi added to the environment.
Installation Prerequisites
- Management workstation with Python 3 installed and Paramiko installed (pip install paramiko)
- CML (I am using 2.2.3) must be installed, configured, and have a bridged network adapter. https://learningnetworkstore.cisco.com/cisco-modeling-labs-personal/cisco-modeling-labs-personal/CML-PERSONAL.html
- An ISO image for Ubuntu Server (I am using 20.04.4) https://ubuntu.com/download/server
- An ISO image for Windows 10 (I am using 21H2) https://www.microsoft.com/en-us/software-download/windows10
- VMware Workstation Pro (I am using v16) https://www.vmware.com/products/workstation-pro/workstation-pro-evaluation.html
- (optional) Raspberry Pi 4 Model B with at least 4GB RAM and a blank 32GB SD card https://www.raspberrypi.com/products/raspberry-pi-4-model-b/ – The steps for the Pi deployment will be covered in the next post.
- (optional) Configure a static route on the LAN for the 10.0.0.0/8 network that points to the IP of the edge router (the default IP is 192.168.1.42). This can also be accomplished by adding static routes on the devices that will need to communicate into the lab.
Installation Process
The easiest way to get the lab up and running is to import a YAML file. This file contains everything you need to get started, but some updates may be required. The lab is configured for internet access, and there is a static IP and gateway assigned. The LAN addressing might need to be updated to match your environment.
If you choose not to use the YAML import you can find the relevant node configurations in the YAML and then create and configure the nodes accordingly.
Expand each of the following sections for steps on how to build out the lab.
The YAML file can be downloaded from GitHub here: https://github.com/mytechgnome/CML-TE-Lab/blob/main/TE.yaml
- Copy the above YAML data into a new file
- Save the file as TE-Lab.yaml
- Log in to CML
- From the Dashboard Click Import
- Click in the File(s) to import area
- Browse to the location the YAML file was saved and select it
- Click Import
- It should import the lab successfully. Click the Go To Lab button
The entire simulation can be started at once, or the individual nodes can be started. If they are being started manually start with the external connection, and work through all the routers first. Then move on to PS3-1. This node will take a few minutes to complete. The remaining CS nodes can be started after PS3-1 completes its startup.
Credentials
Verification tasks
Routers
- show ip route
- The route table should be populated, including a default route
- ping 8.8.8.8
- Should receive replies
- If this fails verify the configuration of Gi0/0 matches the LAN requirements, and the CML VM NIC is configured for bridged access
PS3-1
- systemctl status bind9
- Should display active. If this fails verify internet connectivity and then run these commands:
- sudo apt-get update
- sudo apt install install -o Dpkg::Options::=”–force-confold” bind9 -y
- ping cisco.com
- Should receive replies
CS1-2 and CS2-2
- systemctl status apache2
- Should display active. If this fails verify internet connectivity and then run these commands:
- sudo apt-get update
- sudo apt install apache2
- ping cisco.com
- Should receive replies
- Open VMware Workstation and create a new VM by pressing Ctrl + N
- When the New Virtual Machine Wizard opens click Next
- Select the option for Installer disk image file (iso)
- Enter a username and password, then click Next
- Enter a name for the VM, and verify the path, then click Next
- Set the virtual hard drive to 30GB, then click Next
- Click Customize Hardware
- Select the Network Adapter, change the Network Connection to Bridged, then click Close
- Click Finish
- Wait for the OS installation process to start
- Select your language and press Enter twice to select and confirm
- Use the arrow keys to select the NIC and press Enter
- Highlight Edit IPv4 and press Enter
- Press Enter to change the address assignment method and select Manual
- Use the arrow keys to move between fields filling out the IP address info, and then go to Save and press Enter when complete
- Highlight Done, and press Enter
- Press Enter again to skip the Proxy config
- Press Enter again to use the default mirror location
- Use the arrow keys to highlight Done and press Enter to accept the default storage config
- Press Enter again to accept the file system config
- Highlight Continue and press Enter to confirm the storage settings
- Use the arrow keys to move between fields, fill out the Profile info, and then go to Done and press Enter when complete
- Press Enter again to skip Ubuntu Advantage
- Press Enter to enable SSH access, then highlight Done and press Enter
- Use the arrow keys to go down to highlight Done, and press Enter
- Wait for the installation to complete
- When the installation finishes highlight Reboot Now and press Enter
- When the server is back up log in
- Run the following commands to install Docker
sudo apt-get update
sudo apt-get install
ca-certificates
curl
gnupg
lsb-release
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io -y
Create the Windows VM
- In VMware Workstation press CTRL+N to open the New Virtual Machine Wizard, and make sure Typical is selected, then click Next
- Select the option for Installer Disc Image File, and browse to the location you downloaded the Windows 10 ISO to then click Next
- Enter the name for the client and select the location
- Use the default hard drive size of 60GB (another drive will be added later for the iSCSI target storage), and click Next
- Click Customize Hardware
- Adjust the CPU and RAM as needed for your environment (2 vCPUs 4-8GB RAM would be recommended), and change the Network Adapter from NAT to Bridged
- Click close, verify the box is checked for “Power on this virtual machine after creation” and click finish.
Deploy the Windows OS
NOTE: While in the VM you will need to press Ctrl+Alt to release the cursor to get to your desktop
- >While the VM is booting you might see a prompt to press a key to boot from CD. If that happens click into the window and press a key.
- Select the language, and keyboard settings
- Click Install Now
- On the Activate Windows screen click “I don’t have a product key”
- Select Windows 10 Pro and click Next
- Read through all of the licenses terms, and if you accept the terms check the box to accept them and click Next
- Select the Custom install option
- By default, it should already select Drive 0, which is the 60GB drive initially created. Click next. The OS install will start, so just let that process run.
OS Initial Config
Windows 10 has several steps to go through to get the OS configured before actually loading to a desktop.
- Select your regions and Click Yes
- Select your keyboard layout
- Skip adding the additional keyboard
- Wait a moment for it to progress to the account creation screen, then select “Set up for personal use” and click Next
- Microsoft is going to try to link to an online account, but since this is for a temporary lab PC click on “Offline account” in the bottom left.
- Microsoft really tries to push the online account, so again look in the bottom left corner and select “Limited experience”
- Enter a username and click Next
- Create a password and click Next
- When prompted for the three security questions I just select the first three options and enter random characters. This is a lab, and if I happen to forget the password I can easily recreate the VM. Click Next
- For the privacy settings, this really doesn’t matter, as it’s a lab machine that won’t exist for long. Everything can be left enabled by default, or it can be disabled. After applying the settings click Accept.
- On the Customize Experience page just click Skip
- Cortana… Microsoft really wants people to enable all their stuff. Click “Not now” to move on.
- Success! The post-install prompts are done. Now, wait for the configuration to complete.
Client OS config
To configure the OS there are only two tasks that are going to be performed.
- Install VMware Tools
- Configure DNS
Install VMware Tools
- Log into the VM using the password set previously
- Right-click on the VM in the Library and select Install VMware Tools
- Autorun should prompt to run, but if not then navigate to the D: drive and double click it. That should kick off the Autorun for the installer.
- Follow the defaults for the installation. Next > Next > Install > Finish and then click Yes when prompted for a reboot.
Configure DNS
- Open Powershell as admin
- Press the Windows key and type powershell
- Press Crtl+Shift+Enter to run as admin
- Run these commands:
Set-DnsClientServerAddress -InterfaceAlias Ethernet0 -ServerAddresses 10.133.100.10
Set-DnsClientGlobalSetting -SuffixSearchList cml.lab
There’s a lot to the lab build, but hopefully, it went smoothly. If there were any issues you can add a comment to this post, or reach me on Twitter @Ipswitch.
As the lab build-out continues I may need to come back and edit the configuration here.
CHANGELOG
- CML Lab YAML data
- Corrected IR2-2 Gi0/0 IP configuration and BGP peering
- Corrected IP assignment on PR3-2 – config was moved from Gi0/3 to Gi0/4
- Added loopback interfaces to all routers (will be used for SNMP connections)
- Updated DNS records to use loopback addresses
- Lab config
- Added lab prerequisite to have a management workstation with Python and paramiko
- Added link to Github Repo with YAML file
- Created python script to update routers with v1.1 changes
- https://raw.githubusercontent.com/mytechgnome/CML-TE-Lab/main/v1.1-update.py
- Run the script from a machine with Python and Paramiko installed, and network connectivity to the lab networks.
What’s Next?
The next entry in this series will cover getting the ThousandEyes agent deployed into the lab, and getting things ready to start building tests and collecting data.