[ofa-general] SA: Retrieving multiple paths between SGID and DGID

Sean Hefty mshefty at ichips.intel.com
Wed Dec 19 10:28:53 PST 2007


>         paths_per_dest = 8  (I have set OpenSM LMC=3)
>         lookup_method = 0 (Round robin way to return paths)
> 
> in an intent to retrieve multiple paths. On a single run of my module, 
> it always returned me the same path on multiple calls to 
> ib_sa_path_rec_get. When my  module was unloaded and loaded again, it 
> returned me different path than first run. But, in this second run on 
> successive calls to ib_sa_path_rec_get, it again kept returning me the 
> same path as obtained on the first run. Thus, it looks like successive 
> calls to ib_sa_path_rec_get is not returning me different path on each 
> call.
> 
> If I have to retrieve all 8 paths in a single call, is there any way 
> that I can accomplish the same?

As Hal pointed out, this is using the SA caching.  If you want to obtain 
all paths with a single call, you will need to send your own GetTable 
MAD to the SA using the ib_mad or libibumad interface.

 From your description, either the cache that you're using isn't being 
used or has a bug.  Does this version have a 'refresh' parameter?  If 
so, can you try writing a '1' to that and see if the behavior changes? 
You could also try changing the lookup_method to random (1) to see if 
you see other path records.

- Sean



More information about the general mailing list