Bug 213716

Summary: arping doesn't work on InfiniBand ipoib interfaces
Product: [Fedora] Fedora Reporter: Doug Ledford <dledford>
Component: iputilsAssignee: Martin Bacovsky <mbacovsk>
Status: CLOSED RAWHIDE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: rawhide   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-02-26 14:59:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Fix for arping none

Description Doug Ledford 2006-11-02 18:04:20 UTC
Description of problem: As ipoib interfaces have a 20 byte hardware address, and
a broadcast address that isn't all 0xff, arping fails to send proper packets
over the wire.


How reproducible: 100%


Steps to Reproduce:
1. Setup a machine with ipoib interfaces
2. Run arping in any mode
3.
  
Actual results: It sends no packets because it A) has the wrong hardware
address, B) has the wrong hardware broadcast address and C) passes the wrong
length for the sockaddr struct to both send_to() and recv_from().


Expected results: Should work.


Additional info:  The attached patch still has some debugging info embedded in
it, but it's pretty close to ready to go.  It corrects the problem by using a
"feature" of getsockname() whereby it will overrun the address field if you pass
a large enough buffer to it.  By allocating a double struct for extra padding,
we get the full address.  For the broadcast address, we use sysfs (which adds a
dependency on libsysfs into the arping binary).  We also fix up the length
arguments to recv_from and send_to for the interface.  Using this patch under
RHEL5, tcpdump confirms that the packets are sent over the wire correctly.

Comment 1 Doug Ledford 2006-11-02 18:04:20 UTC
Created attachment 140161 [details]
Fix for arping

Comment 2 Martin Bacovsky 2007-02-26 14:59:32 UTC
Patch applied in iputils-20020927-42.fc7. Please can you check whether it works?