Tierney - stock.adobe.com

Get started Bring yourself up to speed with our introductory content.

The benefits of building a network automation lab

Network teams can build network automation labs to create a safe environment to test and validate automation tasks before running them in production networks.

A network automation lab is valuable to learn network automation skills, as well as create a lab environment in which to verify that automation tasks result in desired network changes.

What is a network automation lab?

A network automation lab is a collection of physical and virtual network devices that emulates the production network for several purposes.

Below are the three main use cases for an automation lab.

  1. Learn network automation. The topology of a network automation lab isn't particularly important because the main goal is to learn automation tools and processes.
  2. Test and validate network automation procedures in a copy of the production network. The lab network should replicate the key features of the production network so network changes can be tested before applying them to the production network. Ideally, this test network is instantiated during the test setup, replicating the part of the network to which the proposed change will be applied.
  3. Train and demonstrate. Network teams can use automation labs to demonstrate a new feature or train staff.

Benefits of a network automation lab

Teams can easily start with a physical lab, provided they have the equipment. However, a virtual network lab has many advantages over using physical devices. We'll focus on building a virtual lab in this article.

The benefits of a virtual network automation lab include the following:

  • A virtual network lab is less expensive.
  • Multiple developers can test their network automations simultaneously.
  • Teams can easily create different network building blocks and interconnect them to mirror the production network's topology.
  • The network lab can be created dynamically using VM hosts, even in cloud provider infrastructures, which reduces or eliminates the need to maintain a physical location.

Virtual device licensing varies, so teams should check with their vendor to determine whether the purchase of a license is required.

Using Vagrant to create a virtual automation lab

Vagrant is the most popular tool to automate the instantiation of test environments, using Oracle VM VirtualBox, VMware, AWS, Kernel VM and other virtualization systems. The virtual network lab configuration is described in a series of Vagrantfiles, the settings of which are merged as they are read. The data-driven approach guarantees that the environment is configured consistently across different developers, on different virtualization platforms and at different times.

Maintain a separate Vagrant configuration file for each network building block -- data center pod, internet edge and branch site, for example -- and only instantiate the building blocks that are needed for a specific test. Each Vagrant file can then be maintained separately from that of other building blocks.

Teams should plan to use a well-provisioned VM platform because network devices tend to have high CPU and memory consumption. Note that Vagrant only creates the virtual network and that another system, like Ansible or shell scripting, is required to configure the virtualized network devices.

Teams must follow many steps and variables to create a virtual network test lab. The articles listed below describe different approaches to building a network lab based on Vagrant:

Making it work

Teams should begin by creating a small network of just two or three devices that give them basic experience with the network test lab. They can then learn how to automate the network testing process with the following steps:

  1. Create a lab instance.
  2. Run the tests.
  3. Destroy the instance.

The result is NetDevOps, a method that provides the ability to develop and test network automation tasks without risk to the production network.

Next Steps

12 network automation ideas to incorporate in your network

This was last published in August 2020

Dig Deeper on Network automation and intent-based networking

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

SearchUnifiedCommunications

SearchMobileComputing

SearchDataCenter

SearchITChannel

Close