Ansible for Arista EoS

This is a continuation of my previous blog on Arista Eapi. Ansible provides a recipe driven approach to manage servers/switches, I have covered Ansible in some of my previous blogs. In this blog, I will cover the following:

  • Ansible modules for Arista device
  • Ansible galaxy eos role for Arista device

There are 2 approaches to use Ansible with Arista device. Following picture from Arista illustrates this point:

arista2

  • The first approach is called remote approach from Ansible perspective. Here the ansible python script is transferred to Arista device using ssh and the python script is executed on the Arista device which connects locally to the device using Pyeapi which in turn talks through eapi.
  • The second approach is called local approach from Ansible perspective. Here the Ansible python script is run locally in the client machine which in turn talks to Pyeapi library which in turn talks to the remote device using eapi.
  • Typically, network devices dont allow running scripts directly on the device. In that case, only second option would be possible. In Arista’s case, there are no restrictions like this and both the approaches can be used for Ansible based automation.

Continue reading Ansible for Arista EoS

Arista Eapi and pyeapi

I had covered basics of Arista EoS and vEoS in my previous blog. Arista’s Eapi gives programmatic approach to manage Arista devices. Arista’s Pyeapi Python  library is built on top of Eapi. In this blog, I will cover the following:

  • Eapi
  • Pyeapi library

I have used Arista vEoS for trying out all examples below without needing a physical Arista device. That shows the power of virtual device.

There is lot of similarity between Arista’s Eapi and Cisco’s NXAPI. I covered NXAPI in 1 of my earlier blogs. Arista’s Eapi is equivalent to Cisco’s NXAPI, Arista’s Pyapi library is equivalent to Cisco’s Pycsco library. Arista’s Eapi provides http/https access to the Arista router/switch through which we can send standard CLI commands and the output is received in JSON/XML formatted output. There is no need to do screen scraping with this approach, this makes it devops friendly. Arista’ Pyeapi is available as a github project.

Eapi:

To enable Eapi in Arista device, do “management api http-commands” in config prompt. Following is the output in my Arista vEoS switch:

Continue reading Arista Eapi and pyeapi

Arista EoS and vEoS

I had heard some good things about Arista EoS(Extensible Operating System). I have never used Arista switches before. I did some reading on Arista EoS and I also tried their VEoS which is their Virtual machine offering for running Arista switch as VM. In this blog, I will share some of my experiences.

EoS Overview:

I found this block diagram in Arista White paper:

arista1

Following are the things that I liked:

Continue reading Arista EoS and vEoS

Ostinato Traffic generator

Every Network engineer would have used Ixia or Spirent for traffic generation. These are generally expensive. For majority of use cases, we need a simple protocol packet generator which can generate packet streams of various protocol types. The recent trend is to move traffic generation application into a VM formfactor. This is more suitable for virtual appliance testing. I recently came across this tool called “Ostinato” from Google and I found it very useful. Even Ixia and Spirent have their traffic generators in VM form factor. I will cover my Ostinato experiences in this blog.

Installing Ostinato:

I installed Ostinato in my Ubuntu 14.04 and 12.04 VM. For Ubuntu 14.04, Ostinato can be installed by:

sudo apt-get install ostinato

The above installs 0.5.1 version. To install later versions(0.6) or to install Ostinato in older Linux versions, use the procedure here.

Starting Ostinato:

Ostinato has a client, server model where servers can be run on multiple hosts and the client can connect to multiple servers. This allows a single client to manage ports present in multiple servers.

To start both client and server:

Continue reading Ostinato Traffic generator

Networking Debug tools

Earlier, I had written a blog on tools that I used with Opendaylight. In that blog, I covered Mininet, dpctl, packeth, Wireshark, Postman. I covered traffic generation tool Ostanito in another blog. There are few other miscellaneous networking tools that I use and I am planning to cover them in this blog. I will try to keep this blog updated as I come across more tools. I will cover the following tools in this blog.


iperf:
iperf is used for tcp and udp performance measurement.
Unicast TCP performance:

Continue reading Networking Debug tools

Cisco Meraki

Cisco acquired Meraki at the end of 2012. I have heard a lot about Meraki and I recently tried to dig deep into what they do. This blog is a result of that.

What does Meraki do?

Meraki does cloud managed access devices for the edge market. Their primary focus is small/medium enterprises. Meraki now has Wireless access points, access switches, security devices. In addition to this, Meraki also provides a mobile management application to remotely monitor and manage mobile devices. All Meraki’s devices have a management connectivity to their backend data center and the devices can be managed remotely. Following picture from Meraki shows the high level data plane/management plane model for all their devices. There is a management connectivity from each device to the backend data center and all centralized management is done from there. Even if the management connectivity is lost, data plane does not get affected.

meraki1

What are Meraki’s differentiators?

Continue reading Cisco Meraki

Cisco NXAPI

Earlier, I had written about Cisco NXOS device configuration/monitoring using Python and OnePK. Recently, I came across NXAPI approach to configure and monitor NXOS  devices. NXAPI uses either http/https to connect to NXOS devices and talk using NXOS CLI. For configuration, CLI is encoded in XML/JSON. For monitoring, CLI is encoded in XML/JSON and the results are returned in similar format that makes it easy to parse. I also saw this blog and nxos-ansible project from Jason where he has created Ansible modules using NXAPI. In this blog, I will cover NXAPI basics and my experience in trying Pycsco library and nxos-ansible modules from Jason. Thanks to Jason, he has done a nice job abstracting the NXAPI into higher level functions and Ansible modules and this can help others to build up on top of it rather than working from scratch.

Enabling NXAPI:

NXAPI is available on Nexus 3k and 9k devices. I have access to N3K device and I tried this there. To enable NXAPI, we need to execute “feature nxapi” from config prompt. NXAPI also provides a sandbox environment which can be accessed using http from the management ip address. With the sandbox environment, we can execute NXOS CLI commands and get output in JSON or XML format. Following image is a snapshot of the sandbox. Continue reading Cisco NXAPI

Embrane – What do they do?

Cisco recently acquired Embrane. I tried to dig deep to answer some questions I had and this blog is a result of that.

What does Embrane do?

Embrane provides L3-L7 Network services and lifecycle management of L3-L7 Network services. Embrane has their own version of Firewall, Load balancers etc and they also partner with vendors like F5, Citrix, A10 to manage their Network Services. Based on my understanding, Embrane’s focus is more on Network service lifecycle management rather than selling Network services itself.

What are Virtual L3-L7 services?

L3-L7 services like Firewall, Load balancers, VPN, Security are traditionally provided with physical boxes. With advances in computing, they can be achieved using a virtual appliance running as VM.

What is Network service lifecycle management?

Continue reading Embrane – What do they do?

Cisco UCS Platform Emulator

Earlier, I had written a blog on Cisco UCS automation using Python SDK. At that time, I used real UCS system to test my scripts. Cisco UCS PE(Platform Emulator) emulates UCSM(UCS Manager) software and we can run this as a VM. Different types of hardware(Fabric Interconnect, FEX/IOM, Servers, adapters, power supply) can be added to create a complex UCS system. We can do majority of the configurations and can trigger different conditions to see how UCSM reacts. Obviously, traffic related testing cannot be done with this. For scripting, UCS PE is a perfect solution. In this blog, I will cover what I did to get UCS PE up and running.

Environment:

VMWare Player 6.05 running on Windows 7.

Installation:

Download the PE zip files. I used version 2.2(3a). Unzip them and import into VMplayer. Choose the default configurations, 3 NAT interfaces are created by default.

Basic configuration:

Continue reading Cisco UCS Platform Emulator

VIRL and CML- L2 connectivity Usecase

This is a continuation of my VIRL, CML blog series. VIRL/CML overview is covered here. In this blog, I will cover L2 connectivity usecase. L3 support has been present in VIRL for quite some time, L2 support was added recently in VIRL. I used the IOSvL2 experimental image for this usecase. Official L2 image is yet to be released.

Following is the topology I created with IOS L2 nodes and servers attached to the nodes.

virl12

Servers1 and 3 are in vlan 10, Server 2 and 4 are in vlan 20. To configure the VLAN, we need to select the link in node view of server and add vlan. I did not add the vlan to the trunk links, Autonetkit automatically adds it. I was not able to specify multiple vlans in the vlan text box, not sure if that’s on purpose. I felt that specifying multiple vlans would be needed for trunking interfaces.

Following is the Autonetkit visualization view in L2 mode.

Continue reading VIRL and CML- L2 connectivity Usecase