Pages

Tuesday, January 13, 2015

Flannel and Docker on Fedora - Getting Started

Lets set up 3 Fedora servers for the purposes of testing flannel on Fedora. These can be bare metal, VMs (on KVM, VMware, RHEV, etc...). Why do we want to test this? This is to demonstrate setting up the flannel overlay network and confirming connectivity. Specifically, I want to test container connectivity across hosts.  I'd like to make sure that container A on host A can talk to container B on host B. I received quite a bit of guidance from Jeremy Eder of breakage.org - Thanks for the tips!

Our 3 Flannel hosts:

fed-master 192.168.121.105
fed-minion1 192.168.121.166
fed-minion2 192.168.121.108

A few setup notes: I haven't looked at this on GCE or AWS. It helps to add the hosts to /etc/hosts, or have some other DNS solution. In my case, I set up these VM's in Vagrant on my laptop and modified /etc/hosts.

Software used on these Fedora hosts.
       
# rpm -qa | egrep "etc|docker|flannel"
flannel-0.2.0-1.fc21.x86_64
docker-io-1.4.0-1.fc21.x86_64
etcd-0.4.6-6.fc21.x86_64


On fed-master:
Look at networking before flannel configuration.
       
# ip a


Start etcd on fed-master.
       
# systemctl start etcd; systemctl status etcd