November 16, 2015

Antonio Ojea

Antonio Ojea

Playing with Virtual and Real Networks: Midonet + GNS3

Playing with Virtual and Real Networks: Midonet + GNS3

The main difference between virtual and real networks is that most of the time the IP packets are not forwarded by real routers and switches, in midonet they are encapsulated and routed by software daemons that create a virtual topology over a real underlay network. These daemons use a central cluster of zookeeper to share the data, you can get more details of the midonet architecture in the repository of the project

Midonet is an overlay network that improves the default Openstack networks, but it can work without Openstack too. However, I think that will be easier to understand how it works with a bit of practice, so we are going to use GNS3 for this.

First, you need GNS3 installed in a linux OS with your favorite appliances ( Cisco, Juniper, Arista, Cumulus, ... ) configured and ready to play.

To try the latest version of midonet with Openstack you only need to do this in your host:

curl -sL | sudo bash

Logging to /opt/quickstart-midonet/quickstart-midonet.log
* Installing basic dependencies... ok.
* Installing python pip... ok.
* Installing and loading virtual env... ok.
* Installing ansible... ok.
--2015-11-12 18:36:50--
Resolving (
Connecting to (||:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 125677 (123K) [application/x-gzip]
Saving to: '/tmp/quickstart-ansible.tar.gz'

100%[==========================================================================================================>] 125,677 58.6KB/s in 2.1s

2015-11-12 18:36:53 (58.6 KB/s) - '/tmp/quickstart-ansible.tar.gz' saved [125677/125677]

* Checking distribution/version... ok.
* Running ansible...
OpenStack Kilo with MidoNet available in
To access through Horizon, use one of the following user/passwords:
* demo/midonet (Demo tenant, demo user)
* admin/midonet (Admin tenant, admin user)
Thanks for trying MidoNet!

Great, we can login in horizon with the credentials mentioned above and launch an instance inside the cloud.

The uplink configured by the quickstart script use a static route and a veth pair. We are going to add a new port to Midonet and configure BGP against a pair of routers so we can connect the cloud against an emulated topology with GNS3 as described below following the next steps:

1) On the host system, add a tap0 interface, a veth pair and connect to a bridge:

ip tuntap add mode tap tap0
ip link add name gns3in type veth peer name gns3out
ip link set up gns3in
ip link set up gns3out
brctl addbr br0
brctl addif br0 tap1
brctl addif br0 gns3int

2) Create a cloud device in GNS3  and add the tap0 interface to it:

3) Configure the Cisco routers to peer against the midonet router, this snippet is from IOU2 router:

router bgp 3
bgp log-neighbor-changes
neighbor remote-as 100

4) Add other port to the midonet router:

midonet> router router0 add port address net
midonet> host host0 add binding port router0:port2 interface gns3out
host host0 interface gns3out port router0:port2
midonet> router router0 set asn 100
midonet> router router0 add bgp-peer asn 3 address
midonet> router router0 add bgp-network net

As you can see the BGP session is established and we can ping from the physical machine to the cloud instance:

September 01, 2015

Sandro Mathys

Sandro Mathys

Analyzing awareness of MidoNet globally

One thing that is hard to measure in open source projects is just how aware people are of your community or its software. It's even harder to find out where in the world people have heard about you so far. You might have a rough feeling, probably based on some facts like the country-specific TLDs of email addresses on your mailing lists. But that's very vague and only includes people actively participating (and there's more and less vocal people, too).

One approach is to check the hits your repository or website is getting. What most people hearing about something for the first time are doing nowadays is quickly check out that something's website. So it's a perfect way to measure where people have at least heard of you!

There's a couple of ways to do this. One way is tracking the IPs that hit your webserver and turn them into a geographical location. Another way is leveraging tools like Google Analytics that you can build into your website. Today, we'll have a brief look at the results for those analytics for, from November 1 until August 31. The data used below is showing numbers of sessions, where a session is defined as starting with the first page impression by a user and ends 30 minute after the user's last page impression. The total duration doesn't matter as much as the fact that any page impressions in between the first and last in a single session are still counting to the same, single session.

Sessions per Country
If you would have given me a map of the world and asked me to color all the countries where I think people have heard of MidoNet, I would have colored the USA and Canada, Europe (minus some South-Eastern parts), East Asia (minus North Korea and Mongolia), Russia and Australia. Again, that's mostly based on where I see activity coming from, plus where I know MidoNet has been presented at some conference or meetup.

However, to my surprise, we've actually seen visitors from many more countries! People are aware of MidoNet almost globally! As you can see on the image below, the map is mostly blue. You can also see, that my expectations weren't totally off the mark as most of the countries I would have colored have a darker hue, indicating more sessions.

Looking at full list of countries reveals that we've had visitors from a total of 122 countries! Admittedly, we've only seen a single session from many of those but it still looks promising. Looking at the top 20 countries by number of sessions, my gut feelings are once more by and large confirmed:
  1. United States
  2. Japan
  3. Russia
  4. China
  5. Spain
  1. South Korea
  2. India
  3. France
  4. Germany
  5. Canada
  1. United Kingdom
  2. Australia
  3. Taiwan
  4. Italy
  5. Brazil
  1. Netherlands
  2. Switzerland
  3. Vietnam
  4. Finland
  5. Norway
Of those, only just Brazil and Vietnam surprised me a little bit, but not enough to go dig for the reasons.

Sessions by City
Well, some countries are just huge while others are smaller than some cities so the above doesn't tell us much about the actual awareness of MidoNet in e.g. the United States, Russia or China. Let's briefly look at cities, but be prepared to see more white than blue on the global map this time. Again, given a map and asked to color it accordingly...well, this one is seriously tough. Obvious high on the list must be Barcelona, Tokyo and San Francisco just because MidoNet's principal sponsor, Midokura, has major offices in those cities. Other than that, I would probably color the economic or technical capital of the countries I would have colored above. Afterwards, I'd just make lots of random dots all over Europe, the US East and West Coats (plus Texas) and that's it. I'd make the bubbles at the Midokura offices as well as those over Seoul, Beijing, Paris and Vancouver fairly bigger and the rest about equally small, again based on where I see activity from, plus we've been promoting MidoNet quite much at the OpenStack Summits in Paris and Vancouver.

Looking at the actual data, I'm not too far off this time. The habitable parts of Europe are covered with dots, and so are the US East and West Coasts. Furthermore, the economical or technical capitals also got dots...and then some.
As I mentioned before, the first map doesn't tell us much about huge countries, but now we see a more detailed image of those countries and can see that actual awareness is much more clustered in only some regions, compared to e.g. Europe or East Asia. But the dots are hard to interpret, let's look at the top 20 cities by number of sessions:
  1. Tokyo
  2. Samara
  3. Barcelona
  4. Seoul
  5. San Francisco
  1. Beijing
  2. New York
  3. Kawasaki
  4. Paris
  5. Bengaluru
  1. Fukuoka
  2. San Jose
  3. Yokohama
  4. Moscow
  5. Santa Clara
  1. Toronto
  2. London
  3. Shanghai
  4. Kansas City
  5. Osaka
No major surprise here, but I'll share some thoughts and facts. First of all, Google Analytics actually lists the single cities that Tokyo is made of - in case you didn't know, Tokyo is not actually a city (anymore) - but I added them up and listed Tokyo instead as otherwise, 6 out of the 20 top ranks would go to Tokyo cities! Also, if you take a train from Tokyo to Yokohama, through Kawasaki (all three listed), you couldn't possibly tell where one ends and the other begins and all of them are home to major tech companies, so no surprise here. Similarly, it's not surprising to see San Jose and Santa Clara listed shortly after San Francisco.

Two smaller surprises came in the form of Samara and Kansas City. Now, when I said I see interested in MidoNet from Russia, I didn't know where in Russia it's coming from. It seems Samara is a major tech city, so seeing Samara and Moscow listed seems plausible but I still wouldn't have expected it on rank #2. Kansas City surprised me a bit more - I know that a local company there is one of our major users, but it's hard to believe that a single company propelled the city into the top 20...

In just 10 months, we have raised awareness for MidoNet all over the globe! Alright, the more detailed analysis by cities draws a bit of a different image, but still a very successful one. All strategically important (i.e. major IT) cities are highlighted, and more. The map also shows that our efforts to promote MidoNet in key areas is very successful and often spreads well outside of the city we were actually visiting.

If I had to predict the coming 10 months, I would first and foremost expect even more interest from the same cities. I don't think we're going to target the regions that are virtually blank on the map as those are mostly regions where cloud technologies have yet to gain traction and SDN/NFV is usually not the first thing people look at. We're trying to put a bit more of a focus on China and India than previously, and continue promoting MidoNet at OpenStack Summits (Tokyo and Austin TX) and Dockercon (Barcelona and ???) but we already see interest from all these places so it's mostly about growth.

Of course, growing interest is only the first step. We also need to convert that interest into users - and the number of users is really the hardest to measure - and finally into contributors, something we're only just at the very beginning of. So continuing to focus on those key areas does make sense, and is still important.