• Icon: Epic Epic
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • None
    • ovs-dpdk
    • None
    • Improve getifaddrs()
    • False
    • False
    • Hide

      Please mark each item below with ( / ) if completed or ( x ) if incomplete:

      ( ) The acceptance criteria defined below are met.


      ( ) The epics work is available in a downstream build (nightly/async or other)


      ( ) Test coverage is available in downstream CI if applicable


      ( ) All cards under the epic have been moved to Done


      ( ) Failed Test Plans have bugs added as children to the epic/feature.

      Show
      Please mark each item below with ( / ) if completed or ( x ) if incomplete: ( ) The acceptance criteria defined below are met. ( ) The epics work is available in a downstream build (nightly/async or other) ( ) Test coverage is available in downstream CI if applicable ( ) All cards under the epic have been moved to Done ( ) Failed Test Plans have bugs added as children to the epic/feature.
    • In Progress
    • rhel-10
    • None
    • rhel-net-ovs-dpdk
    • 67% To Do, 33% In Progress, 0% Done
    • ssg_networking
    • OVS/DPDK - Sprint 15 - East, OVS/DPDK - Sprint 16 - East, OVS/DPDK - Sprint 17 - East
    • 3

      This epic tracks all the effort needed to deliver the solution related to the feature request described below.
      In several places we use glibc's getifaddrs.

      In it's standard implementation (glibc's), this function makes 2 really expensive netlink calls:

      • GETLINK. This collects all interfaces (with full statistics, including inet ones because it does not use RTEXT_FILTER_SKIP_STATS)
      • GETADDR: This collects all the Eth/IPv4/IPv6 addresses in the system

      The obvious first thought is to use RTEXT_FILTER_SKIP_STATS in the first call but on second thought, why use GETLINK at all? The answer is the API exposed by libc.

      The struct returned by getifaddrs contains interface name and its addresses. However, GETADDR returns interface id alongside the addresses. So, the only purpose of the other, very expensive netlink command is to map interface ids to interface names.

      OVS already has the interface id <-> interface name mapping in the netdev_linux struct.

      Therefore, the best approach IMHO would be to replace the getifaddrs implementation altogether with one that only sends GETADDR.

              ovsdpdk-bot ovsdpdk bot
              amorenoz@redhat.com Adrian Moreno
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: