Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ovs-vsctl add-port fail #110

Closed
Fangfenghua opened this issue Mar 15, 2016 · 12 comments
Closed

ovs-vsctl add-port fail #110

Fangfenghua opened this issue Mar 15, 2016 · 12 comments

Comments

@Fangfenghua
Copy link

when i execute ovs-vsctl add-port got a error:
[root@mesos-slave ~]# ovs-vsctl add-br br-test
[root@mesos-slave ~]# ovs-vsctl add-port br-test test-test
ovs-vsctl: Error detected while setting up 'test-test'. See ovs-vswitchd log for details.
[root@mesos-slave ~]#

*_vi /var/log/openvswitch/ovs-vswitchd.log
*_2016-03-15T02:37:14.455Z|00001|ofproto_dpif_upcall(handler10)|INFO|received packet on unassociated datapath port 0
2016-03-15T02:37:14.463Z|00023|bridge|INFO|bridge br-test: added interface br-test on port 65534
2016-03-15T02:37:14.463Z|00024|bridge|INFO|bridge br-test: using datapath ID 00005a871bb49b4b
2016-03-15T02:37:14.463Z|00025|connmgr|INFO|br-test: added service controller "punix:/var/run/openvswitch/br-test.mgmt"
2016-03-15T02:37:24.003Z|00026|bridge|WARN|could not open network device test-test (No such device)

*ENV *
root@mesos-slave ~]# uname -a
Linux mesos-slave 3.10.0-327.10.1.el7.x86_64 #1 SMP Tue Feb 16 17:03:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

[root@mesos-slave ~]# ovs-vsctl -V
ovs-vsctl (Open vSwitch) 2.4.0
Compiled Oct 7 2015 18:01:06
DB Schema 7.12.1
[root@mesos-slave

@blp
Copy link

blp commented Mar 15, 2016

Does a network device named "test-test" exist?

@Fangfenghua
Copy link
Author

When i use version 1.11.0, command ovs-vsctl add-port .... if the port doesn't exist,it will create the port and then add to bridge.

Ref:http://openvswitch.org/support/dist-docs-2.5/ovs-vsctl.8.html

@blp
Copy link

blp commented Mar 15, 2016

ovs-vsctl did create the port and add it to the bridge.

@blp blp closed this as completed Mar 15, 2016
@pascals-ager
Copy link

Hello,

I have a similar issue going with ovs 2.5 on Linux version 4.2 (running on a VM)

root@cep-VirtualBox:/usr/src/ovs/ovs-2.5.0# ovs-vsctl add-port br0 ovs-p0 -- set interface ovs-p0 external-ids:iface-id="p0"
ovs-vsctl: Error detected while setting up 'ovs-p0'. See ovs-vswitchd log for details.
root@cep-VirtualBox:/usr/src/ovs/ovs-2.5.0# ovs-vsctl show
2d64f0cf-c294-44f1-8228-0f367c879b3d
Bridge "br0"
Port "br0"
Interface "br0"
type: internal
Port "ovs-p0"
Interface "ovs-p0"
error: "could not open network device ovs-p0 (No such device)"

Any pointers whatsoever will be helpful.

@jinhao
Copy link

jinhao commented Aug 23, 2017

so does i meet that problem, i use ovs2.6.1 and dpdk 16.11.2

    2017-08-23T09:35:19.411Z|00065|bridge|WARN|could not open network device dpdk-p0 (No such device)
    2017-08-23T09:35:34.819Z|00066|bridge|WARN|could not open network device dpdk-p0 (No such device)

are you solve this problem?

@Fangfenghua @Ad0vith

@louielong
Copy link

The port‘s name should be a exist interface use ifconfig to see, such as eth0. If you just want to use a virtual port name to make a test you should specify the port's type like ovs-vsctl add-port br0 port0 -- set Interface port0 type=internal or ovs-vsctl set Interface port0 type=internal

@krishnakumar3044
Copy link

I am seeing the same issues.

I tried with ovs-vsctl add-port br0 -- set Interface type=dpdk options:dpdk-devargs=0000:00:09.0

With this, I am seeing the same issue. Please let me know, if anyone has resolved this issue. I am using dpdk 16.07.2 with ovs 2.6.1

Thanks

@istokes
Copy link

istokes commented Nov 20, 2018

Arbitrary port names for DPDK ports was only introduced in OVS 2.7. For OVS 2.6 the DPDK port name must be "dpdkn" where n corresponds to the dpdk port as it was added to the userspace driver. Also for 2.6 you should not include the devargs argument for the bus slot function.

You should add the port with the following command instead

ovs-vsctl add-port br0 dpdk0 -- set Interface dpdk0 type=dpdk

To add a second port use

ovs-vsctl add-port br0 dpdk1 -- set Interface dpdk1 type=dpdk

Further details can be found in the OVS 2.6 Docs.

https://github.com/openvswitch/ovs/blob/branch-2.6/INSTALL.DPDK.md#33-setup-ovs

@krishnakumar3044
Copy link

Thanks for the information.

Here is the hw info for the ports

../dpdk-stable-16.07.2/tools/dpdk-devbind.py --status

Network devices using DPDK-compatible driver

0000:00:09.0 '82540EM Gigabit Ethernet Controller' drv=igb_uio unused=
0000:00:0a.0 '82540EM Gigabit Ethernet Controller' drv=igb_uio unused=

How does each port map to corresponding port (Ex: how does dpdk0 map to 0000:00:09.0)

Thanks

@istokes
Copy link

istokes commented Nov 21, 2018

I believe they map in the order they appear in status above. So in this case dpdk0 correspond to 00:09.0. You can confirm this by adding and removing the devices from the igb_uio driver in different orders and testing with ovs-dpdk each time.

However, this method is quite unwieldy in practice, I would encourage you to move to OVS 2.7 at the very least as 2.6 is quite old & support for DPDK was still only experimental at this point in OVS.

@ruyiyao
Copy link

ruyiyao commented Oct 16, 2019

Why it shows Port does not contain a column whose name matches "set"

The port‘s name should be a exist interface use ifconfig to see, such as eth0. If you just want to use a virtual port name to make a test you should specify the port's type like ovs-vsctl add-port br0 port0 -- set Interface port0 type=internal or ovs-vsctl set Interface port0 type=internal

@Deepak610
Copy link

[
Screenshot from 2021-08-24 19-21-06
]
im getting this error,,anyone can help?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants