The purpose of the document is to illustrate the experiment done to validate multicast in a contiv network.
For this experiement we will run 2 containers , one on each VM. We will create a vlan network and run a sender and receiver multicast application. For the purpose of this demo we will be using multicast application from /~https://github.com/leslie-wang/py-multicast-example
$ git clone /~https://github.com/contiv/netplugin
$ cd netplugin
- Start vms
- Create multicast enabled network
$ make demo
$ vagrant ssh netplugin-node1
$ netctl net create contiv-net --encap=vlan --subnet=20.1.1.0/24 --gateway=20.1.1.254 --pkt-tag=1010
$ docker pull qiwang/centos7-mcast
$ docker run -it --name=msender --net=contiv-net qiwang/centos7-mcast /bin/bash
root@9f4e7fd418c5:/# cd /root
root@9f4e7fd418c5:/# ./mcast.py -s -i eth0
vagrant ssh netplugin-node2
$ docker pull qiwang/centos7-mcast
$ docker run -it --name=mreceiver --net=contiv-net qiwang/centos7-mcast /bin/bash
root@564f7f4424c1:/# cd /root
root@564f7f4424c1:/# ./mcast.py -i eth0
('20.1.1.3', 35624) '1453881422.973572'
('20.1.1.3', 35624) '1453881423.977554'
('20.1.1.3', 35624) '1453881424.978941'
where 20.1.1.3 is the IP assigned to container msender.
- Start vms
- Create multicast enabled network
$ make demo
$ vagrant ssh netplugin-node1
$ netctl net create contiv-net --encap=vlan --subnet=20.1.1.0/24 --gateway=20.1.1.254 --pkt-tag=1010
$ sudo ovs-vsctl add-port contivVlanBridge inb01 -- set interface inb01 type=internal
$ sudo ovs-vsctl set port inb01 tag=1010
$ sudo ifconfig inb01 30.1.1.8/24
$ ./mcast.py -s -i inb01
$ vagrant ssh netplugin-node2
$ docker pull qiwang/centos7-mcast
$ docker run -it --name=mreceiver --net=contiv-net qiwang/centos7-mcast /bin/bash
root@426b8cdbf5f8:/# cd /root
root@426b8cdbf5f8:/# ./mcast.py -i eth0
('30.1.1.8', 35678) '1453882966.102203'
('30.1.1.8', 35678) '1453882967.120764'
('30.1.1.8', 35678) '1453882968.12215'