[ovs-discuss] ovs-vswitchd bridge datapath_type netdev doesn't work with ovs-ofctl (br0 is not a bridge or a socket)
Daniel Badea
daniel.badea at windriver.com
Thu Oct 2 10:43:50 UTC 2014
It works. I added flows between dpdk port and VM port:
./ovs/utilities/ovs-ofctl show br0
# OFPT_FEATURES_REPLY (xid=0x2): dpid:0000001b21a3e9f8
# n_tables:254, n_buffers:256
# capabilities: FLOW_STATS TABLE_STATS PORT_STATS QUEUE_STATS ARP_MATCH_IP
# actions: output enqueue set_vlan_vid set_vlan_pcp strip_vlan mod_dl_src
mod_dl_dst mod_nw_src mod_nw_dst mod_nw_tos mod_tp_src mod_tp_dst
# 1(dpdk0): addr:00:1b:21:a3:e9:f8
# config: 0
# state: 0
# current: 10GB-FD
# supported: 10MB-HD 100MB-HD FIBER AUTO_NEG AUTO_PAUSE
# speed: 10000 Mbps now, 100 Mbps max
# 2(dpdk1): addr:00:1b:21:a3:e9:f9
# config: 0
# state: LINK_DOWN
# current: AUTO_NEG
# supported: 1GB-HD 1GB-FD 10GB-FD FIBER AUTO_NEG AUTO_PAUSE
AUTO_PAUSE_ASYM
# speed: 0 Mbps now, 10000 Mbps max
# 3(vnet1): addr:fe:54:00:95:af:b8
# config: 0
# state: 0
# current: 10MB-FD COPPER
# speed: 10 Mbps now, 0 Mbps max
# LOCAL(br0): addr:00:1b:21:a3:e9:f8
# config: PORT_DOWN
# state: LINK_DOWN
# current: 10MB-FD COPPER
# speed: 10 Mbps now, 0 Mbps max
# OFPT_GET_CONFIG_REPLY (xid=0x4): frags=normal miss_send_len=0
./ovs/utilities/ovs-ofctl add-flow br0 in_port=1,action=output:3
./ovs/utilities/ovs-ofctl add-flow br0 in_port=3,action=output:1
and ran performance tests using iperf UDP then TCP:
iperf -u -c 192.168.1.1 -t 120 -b 2000M
# ------------------------------------------------------------
# Client connecting to 192.168.1.1, UDP port 5001
# Sending 1470 byte datagrams
# UDP buffer size: 208 KByte (default)
# ------------------------------------------------------------
# [ 3] local 192.168.1.10 port 57311 connected with 192.168.1.1 port 5001
# [ ID] Interval Transfer Bandwidth
# [ 3] 0.0-120.0 sec 11.4 GBytes 815 Mbits/sec
# [ 3] Sent 8312289 datagrams
# [ 3] Server Report:
# [ 3] 0.0-120.0 sec 9.52 GBytes 681 Mbits/sec 0.002 ms
1359992/8312288 (16%)
# [ 3] 0.0-120.0 sec 1 datagrams received out-of-order
iperf -c 192.168.1.1 -t 300
# ------------------------------------------------------------
# Client connecting to 192.168.1.1, TCP port 5001
# TCP window size: 85.0 KByte (default)
# ------------------------------------------------------------
# [ 3] local 192.168.1.10 port 46246 connected with 192.168.1.1 port 5001
# [ ID] Interval Transfer Bandwidth
# [ 3] 0.0-300.0 sec 37.7 GBytes 1.08 Gbits/sec
(VM uses 4 vCPUs)
Best regards,
Daniel
-----Original Message-----
From: Daniele Di Proietto [mailto:ddiproietto at vmware.com]
Sent: Wednesday, October 1, 2014 11:12 PM
To: Daniel Badea
Cc: discuss at openvswitch.org
Subject: Re: [ovs-discuss] ovs-vswitchd bridge datapath_type netdev doesn't
work with ovs-ofctl (br0 is not a bridge or a socket)
Hi,
I've been able to reproduce the issue. A fix has been pushed to master
(commit 58f195398e4d).
Can you please confirm this solves the problem for you?
Thanks for the bug report,
Daniele
On 10/1/14, 5:55 AM, "Daniel Badea" <daniel.badea at windriver.com> wrote:
>I¹m trying to configure a flow between a DPDK port and a VM virtio port.
>Following instructions here:
>https://github.com/openvswitch/ovs/blob/master/INSTALL.DPDK
><https://urldefense.proofpoint.com/v1/url?u=https://github.com/openvswi
>tch
>/ovs/blob/master/INSTALL.DPDK&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=MV9
>BdL
>jtFIdhBDBaw5z%2BU6SSA2gAfY4L%2F1HCy3VjlKU%3D%0A&m=i5FlS%2BxVCtWiikYTRrE
>%2B
>GHBWY4d7tRrW6stZ3pOKMmw%3D%0A&s=059e44c5af0ae41703d9fe7885ff4da69fd0edb
>123
>da8d4cfb5052f29793a2b7>
>
>I created br0 bridge, set dapapath_type to ³netdev², added dpdk0 and
>dpdk1 ports and created a virsh host with the following configuration:
>
>
> <interface type='bridge'>
> <mac address='52:54:00:95:af:b8'/>
> <source bridge='br0'/>
> <virtualport type='openvswitch'>
> <parameters interfaceid='d45aa931-1d3e-4c32-be8c-5091f1cb6134'/>
> </virtualport>
> <model type='rtl8139'/>
> <address type='pci' domain='0x0000' bus='0x00' slot='0x05'
>function='0x0'/>
> </interface>
>
>As expected, this creates bridge br0 and ports vnet1, dpdk0 and dpdk1.
>
>But when trying to configure a flow between vnet and dpdk ports
>ovs-ofctl fails with:
>
> ³br0 is not a bridge or a socket²
>
>A quick investigation reveals the problem appears when br0 bridge
>datapath_type is changed to ³netdev². Somehow
>/usr/local/var/run/openvswitch/br0.mgmt socket is removed and ovs-ofctl
>can¹t find the bridge. ovs-vsctl is probably using another mechanism
>to list bridge information because it works when ovs-ofctl doesn¹t.
>
>Simplified steps to reproduce and corresponding output of ovs-vswitchd
>(commands executed as root).
>
>./utilities/ovs-vsctl add-br br0
>
># ovs-vswitchd output
>#
># 2014-10-01T12:24:55Z|00049|dpif|WARN|system at ovs-system: failed to
>put[create] (Invalid argument)
>skb_priority(0),skb_mark(0),recirc_id(0x1),dp_hash(0x1),in_port(0),eth(
>src
>=00:00:00:00:00:00,dst=00:00:00:00:00:00)
># 2014-10-01T12:24:55Z|00050|ofproto_dpif|INFO|system at ovs-system:
>Datapath does not support recirculation #
>2014-10-01T12:24:55Z|00051|dpif|WARN|system at ovs-system: failed to
>put[create] (Invalid argument)
>skb_priority(0),skb_mark(0),in_port(0),eth(src=00:00:00:00:00:00,dst=00
>:00
>:00:00:00:00),eth_type(0x8847),mpls(label=0,tc=0,ttl=0,bos=1)
>#2014-10-01T12:24:55Z|00052|ofproto_dpif|INFO|system at ovs-system: MPLS
>label stack length probed as 0 #
>2014-10-01T12:24:55Z|00053|dpif|WARN|system at ovs-system: execute
>set(eth(src=53:53:53:53:53:53/7f:7f:7f:7f:7f:7f,dst=53:53:53:53:53:53/7
>f:7
>f:7f:7f:7f:7f)) failed (Invalid argument) on packet
>metadata=0,in_port=0,vlan_tci=0x0000,dl_src=00:00:00:00:00:00,dl_dst=00
>:00
>:00:00:00:00,dl_type=0x1234
># 2014-10-01T12:24:55Z|00054|ofproto_dpif|INFO|system at ovs-system:
>datapath does not support masked set action feature.
>#
>2014-10-01T12:24:55Z|00001|ofproto_dpif_upcall(handler343)|INFO|receive
>d
>packet on unassociated datapath port 0
># 2014-10-01T12:24:55Z|00055|bridge|INFO|bridge br0: added interface
>br0 on port 65534 # 2014-10-01T12:24:55Z|00056|bridge|INFO|bridge br0:
>using datapath ID
>0000f2f5632d0d47
># 2014-10-01T12:24:55Z|00057|connmgr|INFO|br0: added service controller
>"punix:/usr/local/var/run/openvswitch/br0.mgmt"
>
>./utilities/ovs-ofctl show br0
>
># OFPT_FEATURES_REPLY (xid=0x2): dpid:0000f2f5632d0d47 # n_tables:254,
>n_buffers:256 # capabilities: FLOW_STATS TABLE_STATS PORT_STATS
>QUEUE_STATS ARP_MATCH_IP # actions: output enqueue set_vlan_vid
>set_vlan_pcp strip_vlan mod_dl_src mod_dl_dst mod_nw_src mod_nw_dst
>mod_nw_tos mod_tp_src mod_tp_dst # LOCAL(br0): addr:f2:f5:63:2d:0d:47
># config: PORT_DOWN
># state: LINK_DOWN
># speed: 0 Mbps now, 0 Mbps max
># OFPT_GET_CONFIG_REPLY (xid=0x4): frags=normal miss_send_len=0
>
>ls -1 /usr/local/var/run/openvswitch | grep br0
>
># br0.mgmt
># br0.snoop
>
>./ utilities/ovs-vsctl set bridge br0 datapath_type=netdev
>
># ovs-vswitchd output
>#
># 2014-10-01T12:26:11Z|00058|ofproto_dpif|INFO|netdev at ovs-netdev:
>Datapath supports recirculation
># 2014-10-01T12:26:11Z|00059|ofproto_dpif|INFO|netdev at ovs-netdev: MPLS
>label stack length probed as 3 #
>2014-10-01T12:26:11Z|00060|bridge|INFO|bridge br0: added interface br0
>on port 65534 # 2014-10-01T12:26:11Z|00061|netdev_linux|WARN|br0:
>obtaining netdev stats via vport failed (No such device) #
>2014-10-01T12:26:11Z|00062|bridge|INFO|bridge br0: using datapath ID
>0000f2f5632d0d47
># 2014-10-01T12:26:11Z|00063|connmgr|INFO|br0: added service controller
>"punix:/usr/local/var/run/openvswitch/br0.mgmt"
># 2014-10-01T12:26:15Z|00064|netdev_linux|WARN|br0: obtaining netdev
>stats via vport failed (No such device)
>
>./utilities/ovs-ofctl show br0
>
># ovs-ofctl: br0 is not a bridge or a socket
>
>ls -1 /usr/local/var/run/openvswitch | grep br0
>
># br0.snoop
>
>./utilities/ovs-vsctl show
># 3a8ba2cd-1749-4c2a-8fd4-c4b7429cea87
># Bridge "br0"
># Port "br0"
># Interface "br0"
># type: internal
>
>./utilities/ovs-vsctl del-br br0
>
># ovs-vswitchd output
>#
># 2014-10-01T12:27:04Z|00003|fatal_signal(urcu1)|WARN|could not unlink
>"/usr/local/var/run/openvswitch/br0.mgmt" (No such file or directory)
>
>Repositories & versions used:
>
>cd ovs; git log -n1 --pretty=format:%H%d; grep url .git/config; cd ..
># a07e26bf367075d7b31f3f180b65605412b0624b (HEAD, origin/master,
>origin/HEAD, master) # url = https://github.com/openvswitch/ovs.git
>
>cd dpdk; git log -n1 --pretty=format:%H%d; grep url .git/config; cd ..
># 9db7084fcdf6d57b892312ca641a97356629c04a (HEAD, v1.7.0) # url =
>git://dpdk.org/dpdk
>
>Is this a configuration issue?
>
>Thanks,
>Daniel
>
>
More information about the discuss
mailing list