title: How to build perftest and run latency tests on RDMA
body: <p>I'm trying to build the <a href="https://github.com/linux-rdma" rel="nofollow noreferrer">perftest C library</a> to run some latency tests over the RDMA protocol.</p>
  <p>My steps:</p>
  <ul>
  <li><p>I downloaded the library from <a href="https://github.com/linux-rdma" rel="nofollow noreferrer">their GitHub</a> and unzipped it on the box on which I want to run the server for the tests</p>
  </li>
  <li><p>I executed:</p>
  <p><code>./autogen</code></p>
  <p><code>./configure</code></p>
  <p><code>make clean &amp;&amp; make V=1</code></p>
  </li>
  </ul>
  <br>
  <ul>
  <li><p>I tried to run a test</p>
  <p><code>./ib_send_lat --duration=30 -H</code></p>
  </li>
  </ul>
  <p>..but I get the <strong>following error</strong>:</p>
  <pre><code>Port number 1 state is Down
  Couldn't set the link layer
  Couldn't get context for the device
  </code></pre>
  <p>What am I doing wrong?</p>
  <p>Running other tests that use the RDMA protocol (eg. <a href="https://github.com/accelio/accelio/tree/fd3c54c907a3e5d5f218361e0a596930afe826e4/tests/usr/hello_test_lat" rel="nofollow noreferrer">the ones in Accelio</a>) the system shows no problems.</p>
  <p>Also, I runned a few diagnostic tools and everything seems configured correctly already:</p>
  <ul>
  <li><p>Verified that RDMA kernel part is loaded (<em>ibuverbs</em> present)
  <a href="https://i.stack.imgur.com/lgCEo.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/lgCEo.png" alt="enter image description here" /></a></p>
  </li>
  <li><p>Verified that RDMA devices are available
  <a href="https://i.stack.imgur.com/8yWvZ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/8yWvZ.png" alt="enter image description here" /></a></p>
  </li>
  <li><p>Verified that RDMA devices can be accessed (the second one says PORT_ACTIVE)
  <a href="https://i.stack.imgur.com/27sbe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/27sbe.png" alt="enter image description here" /></a></p>
  </li>
  <li><p>Verified that traffic over RDMA is working sending messages from a client to a server using rping <a href="https://i.stack.imgur.com/43HuI.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/43HuI.png" alt="enter image description here" /></a></p>
  </li>
  </ul>
  <p>Any suggestions? (I opened an <a href="https://github.com/linux-rdma/perftest/issues/43" rel="nofollow noreferrer">issue</a> on their GitHub but I got no reply yet)</p>
  <p>Thanks</p>