Closed menossi closed 10 years ago
You need to move those interfaces to different network namespaces. Try this:
## create veth interfaces
sudo ip link add veth0 type veth peer name veth1
sudo ip link add veth2 type veth peer name veth3
## create n1 namespace for veth0 and configure
sudo ip netns add n1
sudo ip netns exec n1 ip link set lo up
sudo ip link set veth0 netns n1
sudo ip netns exec n1 ip addr add 10.0.0.1/8 dev veth0
sudo ip netns exec n1 ip link set veth0 up
## create n2 namespace for veth1 and configure
sudo ip netns add n2
sudo ip netns exec n2 ip link set lo up
sudo ip link set veth2 netns n2
sudo ip netns exec n2 ip addr add 10.0.0.2/8 dev veth2
sudo ip netns exec n2 ip link set veth2 up
## start switch
sudo ofdatapath --datapath-id=000000000001 --interfaces=veth1,veth3 ptcp:6632
## try ping // no luck :(
sudo ip netns exec n1 ping 10.0.0.2
## add flows
sudo dpctl tcp:127.0.0.1:6632 flow-mod table=0,cmd=add in_port=1 apply:output=2
sudo dpctl tcp:127.0.0.1:6632 flow-mod table=0,cmd=add in_port=2 apply:output=1
## try ping // it works! :)
sudo ip netns exec n1 ping 10.0.0.2
That works! Thanks @ZoltanLajosKis
I'm trying to use the openflow switch without the Mininet. So i did:
Then i started the switch:
Start the libfluid controller:
Created the switch<->controller connection:
For the test, i've done:
Then:
And didn't worked.
Using dpctl monitor i get: not_match
I've started without the controller and tryed to install flows manually:
But doesn't work also.
I tested with Mininet, the switch and the controller and worked well... I don't know i've done wrong...
Can someone help me, please?