[Bug 1625542] Re: --vhost-owner --vhost-perm no more transferred to DPDK EAL commandline

Timo Koehler tikoehle at googlemail.com
Mon Sep 26 17:26:36 UTC 2016


After a reboot and restart of ovs-vswitchd I have seen these EAL logs
pointing to the problem:

EAL: vhost-user socket cannot set permissions to 0664 (Unknown error -1).
EAL: vhost-user socket unable to set ownership to libvirt-qemu:kvm (Unknown error -1).
VHOST_CONFIG: vhost-user server: socket created, fd: 41
VHOST_CONFIG: bind to /var/run/openvswitch/vhu6ef65d50-d7

Then I looked into vhost-net-user.c:rte_vhost_driver_register(). I have
seen that rte_eal_set_socket_permissions(path) is done before the socket
actually created and then I moved this call into
vhost_user_create_server() after bind() and it started to work. Attached
is the patch. I hope that makes sense (also need this in
vhost_user_create_client() ?) . After rebuilding dpdk and restart ovs-
vswitchd it looks better and nova boot now works.

Starting ovs-vswitchd:
:::
Zone 0: name:<rte_eth_dev_data>, phys:0x1bfffced40, len:0x30100, virt:0x7f40fffced40, socket_id:1, flags:0
VHOST_CONFIG: vhost-user server: socket created, fd: 41
VHOST_CONFIG: bind to /var/run/openvswitch/vhu6c018db8-c2
EAL: Socket /var/run/openvswitch/vhu6c018db8-c2 changed permissions to 0664
EAL: Socket /var/run/openvswitch/vhu6c018db8-c2 changed ownership to libvirt-qemu:kvm.
VHOST_CONFIG: vhost-user server: socket created, fd: 48
VHOST_CONFIG: bind to /var/run/openvswitch/vhu6ef65d50-d7
EAL: Socket /var/run/openvswitch/vhu6ef65d50-d7 changed permissions to 0664
EAL: Socket /var/run/openvswitch/vhu6ef65d50-d7 changed ownership to libvirt-qemu:kvm.

root at compute29:~# ll /var/run/openvswitch/
:::
srw-rw-r--  1 libvirt-qemu kvm     0 Sep 26 11:09 vhu6c018db8-c2=
srw-rw-r--  1 libvirt-qemu kvm     0 Sep 26 11:09 vhu6ef65d50-d7=
srw-rw-r--  1 libvirt-qemu kvm     0 Sep 26 11:16 vhu927b950f-f1=  <<---- nova booted new vm



** Patch added: "Moves rte_eal_set_socket_permissions() into vhost_user_create_server()"
   https://bugs.launchpad.net/ubuntu/+source/dpdk/+bug/1625542/+attachment/4748866/+files/dpdk_vhost_permission_tikoehle.patch

-- 
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to openvswitch in Ubuntu.
https://bugs.launchpad.net/bugs/1625542

Title:
  --vhost-owner --vhost-perm no more transferred to DPDK EAL commandline

Status in dpdk package in Ubuntu:
  Incomplete
Status in openvswitch package in Ubuntu:
  Triaged

Bug description:
  Hi,
  this was reported by an early tester of OVS 2.6 / DPDK 16.07 packages in yakkety.

  TL;DR
   - the old --vhost-owner --vhost-perm seem no more to be passed to the DPDK commandline
   - OVS complains about ovs-vswitchd: unrecognized option '--vhost-owner'

  Example:
  ovs-vswitchd \
  --vhost-owner libvirt-qemu:kvm \
  --vhost-perm 0664 \
  -- unix:$DB_SOCK -vconsole:emer -vsyslog:err -vfile:info \
  --mlockall --no-chdir \
  --log-file=/var/log/openvswitch/ovs-vswitchd.log \
  --pidfile=/var/run/openvswitch/ovs-vswitchd.pid --detach --monitor
  ovs-vswitchd: unrecognized option '--vhost-owner'

  I expect this to be either of these two:
  - actually those should be after a --dpdk switch to get to the DPDK EAL commandline. Just how we describe it at https://help.ubuntu.com/16.04/serverguide/DPDK.html#dpdk-openvswitch
  OR
  - An upstream change on OVS 2.6 now interferes and breaks the passing of these options. A lot was changed to push DPDK config to the ovsdb so this can be possible.

  See http://openvswitch.org/support/dist-docs/INSTALL.DPDK-
  ADVANCED.md.html for most of the new other_config values.

  I expect to be the second more than the first case due to DPDK
  configuration being completely changed into an ovsdb based operation.
  Search for dpdk here http://openvswitch.org/support/dist-docs/ovs-
  vswitchd.conf.db.5.html.

  But since neither DPDK nor OVS took the ownership control patches
  (https://www.mail-archive.com/dev@openvswitch.org/msg69706.html) it
  has to be a delta that we add once we have final OVS 2.6.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/dpdk/+bug/1625542/+subscriptions



More information about the Ubuntu-openstack-bugs mailing list