EarIier I wrote about some ways to modify VM disk images used by Unetlab. Basically it boils down to running a VM, console to it and change things through its shell. Obviously, this approach is no way near a handy way to do small changes like:
- loading basic config
- adding license files
In this post I will talk about
guestfish utility which is a part of
libguestfs tools set. With
guestfish one could easily get a shell-like access to the filesystem located on a disk image (qcow2, vmdk, iso and many others). That is how authors of
libguestfs tools describe it:
libguestfs is a set of tools for accessing and modifying virtual machine (VM) disk images
. You can use this for viewing and editing files inside guests, scripting changes to VMs, monitoring disk used/free statistics
, creating guests
, P2V, V2V
, performing backups, cloning VMs, building VMs, formatting disks, resizing disks, and much more.
libguestfs can access almost any disk image imaginable. It can do it securely — without needing root and with multiple layers of defence against rogue disk images. It can access disk images on remote machines or on CDs/USB sticks. It can access proprietary systems like VMware and Hyper-V.
To demonstrate the way how guestfish works I will solve a particular task of adding a license file to Nokia (Alcatel-Lucent) 7750 Virtual Service Router (VSR) by embedding it to the disk image itself. Tune in!
We are, network engineers, have many *nix tools at our disposal: exaBGP, nmap, tcpdump, to name a few. And with UNetlab its very easy to run a linux system inside a topology (not to mention that you could use cloud
pnet interface to bridge unetlab topology with the real world). By default UNetLab’s linux template opts to VNC access, which is cool if you have a GUI, but for a networker – CLI is the only love. In this post I will share with you a method to get telnet access to a linux image inside the UNetLab.
All credits go to my colleague – Anatoliy Kolpakov.
A good tutorial on what is ESXi Web Client Interface is, how to install and maintain it by http://www.vladan.fr/
I advertised to you recently another great virtual lab environment – Unified Networking Lab – with tools like that one I practiced the cool technologies of Alcatel-Lucent Service Routing platform and prepared to many certification exams. And I encourage you to go the same way, not just read the books and force the dumps, but actually build a topology and walk through interesting scenarios.
If you boot a Cisco router like 7210 one, or even Juniper vMX, you could configure some interfaces, protocols and so on right away. With Alcatel-Lucent 7750 SR this approach doomed to fail, you should know how bring to life 7750 virtual Service Router (vSR) once you booted it before any further configuration steps.
And this short post will be just about that, what should you configure on 7750 SR after the first boot to make it running with Unetlab or GNS3?
Since QEMU is the main tool I use in our virtual lab, it is crucial to know what qemu in general is and what are all the qemu options for? And I am no expert here, actully I ran some qemu images myself without honest understanding why am I providing this particular set of options and invoking qemu like that.
So to save myself some time in further searching for a good qemu guides and how-to’s I will keep here links about it I personally find useful
- Qemu page on an Arch linux wiki
- OpenSuse beautiful guide on Qemu
Having a traffic generator in a lab is a huge advantage, hands down. As to this moment Unified Networking Lab supports software-based traffic generator called Ostinato. But I had an opportunity to use another traffic generator – Spirent Test Center, virtual edition.
Spirent’s images are not officially integrated/supported by UNL, so you will see how to add something that is not supported yet by Unetlab.
I had 1.99.1 beta running in Mavericks quite well, problems arose with upgrade to 10.10. Yosemite. I saw
Error from waitpid(): Interrupted system call. every time wireshark started and did not see any interfaces to start capture on.
Thanks I was not alone with this one, go to the link provided to see the details, or do not give a sh*t and apply this one liner fix:
sudo dseditgroup -o edit -a -t user access_bpf
You may have to restart wireshark one/two times till changes take effect.
Juniper offers its brilliant MX routers for virtual environments – namely vMX. And we cant name ourselves engineers if we wouldn’t try to run one in the Unetlab. Running vMX in the unetlab is a simple task, yet I see many complaints about vMX not working. With this being said I invite you to a journey called “running vMX in Unetlab. Painless edition”.
Of course you heard of qemu. Its a hypervisor used by UNetLab and GNS3 to integrate virtual routers like Alcatel-Lucent’s 7750 SR, Junipers vMX and Cisco’s XRv. And it is well-known that those virtual routers come in the form of qemu disk images with an odd
qcow2 extension. But how can we alter those disc images if we need, for example, preconfigure and distribute an image with some interfaces configured, or got system name changed or even upload a license file?
I invite you to acquire this useful knowledge under the cut section.
ADD: I wrote another post on how to do this stuff automatically with
A long time ago in a galaxy far, far away engineers hunted eBay for used routers to meet their demand for home labbing. Rack-rental services were kings and an ability to run cisco ios under dynamips felt like pure magic. Those dark days are gone… Thanks to massive eruption of virtualization technologies.
In this topic I will introduce you to Unified Networking Lab (UNL) – web-based tool which is capable to run so many images in a so convenient way that you might read this whole topic with your jaw opened.
Want to know how to run Cisco, Juniper, Alcatel-Lucent, F5, Vyatta, Mikrotik and dozens of other networking OSes? You came to the right place.
This post is the most popular one at this blog, it outstands other topics by far and the reason is simple — UNL is a solid tool that helped many of us to reach our goals and it was completely free.
At this moment UNL team is looking for our help in their pursuit of making a better product — EVE-NG — which is an evolution of UNL and has a lot of planned improvements and new features. For a complete list of features and a demo of EVE refer to their campaign on Indiegogo.
We are community, we help each other.