I'm using flannel for the first time and I'm testing it with two nodes (Ubuntu14.04) with etcd running. The ip addresses of the two nodes are 192.168.0.124 (node1) and 192.168.0.127 (node2), and they can ping each other without problem. I have configured flannel network in etcd as follows:
On node1: etcdctl set /coreos.com/network/config '{ "Network": "10.1.15.0/16" }'
On node2: etcdctl set /coreos.com/network/config '{ "Network": "10.1.20.0/16" }'
However, whenever I run flanneld on either node I get the following error:
E0523 14:11:29.325240 28803 network.go:71] Failed to initialize network (type UDP): Failed to open TUN device: ioctl failed with 'operation not permitted'
Is there any clue on solving this problem?
It turned out to be a permission issue. Simply sudo flanneld
will work.