Category: labs
Building Your Own Virtual Lab
Last week we published Matt Oswalt’s thoughts on using virtual labs in training and testing. In the second part of his interview with Christoph Jaggi he talked about building a virtual lab.
Matt will cover the same topic in way more details in his guest speaker presentation in Spring 2019 Building Network Automation Solutions online course. Register here.
Using Virtual Labs When Developing Network Automation Solutions
One of the fundamentals I always emphasize in introductory parts of my network automation workshops and online courses is the fact that we’re about to develop software that will control the most-mission-critical part of IT infrastructure, and should therefore use software development methodologies like version control, testing…
However, there’s a “small” glitch. While it’s perfectly possible to test most software in some virtual environment you can spin up on-the-fly using Vagrant, Docker, Jenkins, Travis, or some other CI/CD tool, testing a network automation solution requires access to network devices.
Network Automation Development Environments
Building the network automation lab environment seems to be one of the early showstoppers on everyone’s network automation journey. These resources might help you get started:
- I wrote an installation script that installs the myriad dependencies needed by Ansible and NAPALM in just the right order on a Ubuntu VM (step-by-step instructions for ipSpace.net subscribers).
- Carl Buchmann open-sourced a full-blown infrastructure-as-code development environment he uses for his automation projects.
- Jaap de Vos described how he creates a Docker image containing Ansible, NAPALM and Nornir.
Hint: after setting up your environment, you might want to enroll into the Spring 2019 network automation course ;)
Create Ansible Inventory File from Vagrant SSH Configuration
While it’s relatively easy to create an Ansible inventory file to support a Vagrant-created virtual networking lab, it’s also utterly boring – a perfect job for an automation script. I’m positive there are a zillion solutions out there, but I decided to reinvent the wheel and get a bit of Python hands-on practice.
Setup DNS server in your lab
Simplify your lab work
If you do a lot of tests in a router lab, you're probably getting upset when you have to retype the login and enable password whenever you log into a router. What I do in my labs is to disable VTY login, set the default privilege level to 15 and disable exec timeout (to stop the router from terminating my session).
line con 0
exec-timeout 0 0
privilege level 15
line vty 0 4
exec-timeout 0 0
privilege level 15
no login
Obviously, this would not bring you additional points on the CCIE lab exam :)