One of the things I hear a lot from those who are just trying to get into Networking is that people think they need to have access to physical network devices to get hands-on experience. This is not true at all, and I want to clear that up to help people become aware of the possibilities and options.
In my previous post Managing SSH Logins The Way You Are Supposed To I talked about how you should use the SSH config file to manage your SSH login details. The lab example that we used is 1 SSH client and 2 SSH servers which are both 1 hop from the client. 1 hop in a sense that both can be accessed directly from the client. There is nothing standing in between any of them.
Do you ever find yourself trying to remember all the server names or IP addresses along with the usernames you need to log in to them? And what if you're using SSH key-based authentication (like I discussed here) and you're using different keys on different group of servers. It's actually not practical to maintain all of this information externally. In fact, you really are supposed to manage this in SSH itself.
In my last post How To Configure SSH Key-based Authentication on Linux, I gave a walkthrough on how to set up SSH keys with an SSH agent so you get the benefits of passwordless logins while still maintaining the increased security that key-based authentication is supposed to provide. The reason why I reiterate this is because using SSH keys without passphrases pretty much defeats the purpose of using keys at all.
In my last post about The Easiest Way to Build a Network Automation Lab, I have introduced the topic of SSH key-based authentication. Although that post was specific to Networking, this particular post is quite applicable to anything Linux and UNIX-like. I will specifically be performing all procedures on Centos 7 but by no means it will not apply to other Linux distributions. There should be minimal differences, if not, none at all. Let's dive in.
For some time I have been trying different things on how to build a good Network Automation Lab. You would think that this can be as trivial as just your typical GNS3 lab hooked up with some VMs where you can launch your scripts, but in my mind, I wanted something very simple and straightforward, pretty much painless approach to building one. I had a good idea of how this kind of lab should be. Below are the points which guided me in my search for the right kind of setup.