Mentions légales du service

Skip to content
Snippets Groups Projects

[lyon/neowise] Add ib_map for neowise

Merged BERARD Benjamin requested to merge neowise into master
1 file
+ 2
1
Compare changes
  • Side-by-side
  • Inline
@@ -388,7 +388,8 @@ def get_ref_node_properties_internal(cluster_uid, cluster, node_uid, node)
# INFINIBAND
ni_mountable = node['network_adapters'].select { |na| /^ib[0-9]*(\.[0-9]*)?$/.match(na['device']) && (na['interface'] == 'InfiniBand' and na['enabled'] == true && (na['mounted'] == true || na['mountable'] == true)) }
ni_fastest = ni_mountable.max_by { |na| na['rate'] || 0 }
ib_map = { 0 => 'NO', 10 => 'SDR', 20 => 'DDR', 40 => 'QDR', 56 => 'FDR', 100 => 'EDR' }
# https://en.wikipedia.org/wiki/InfiniBand
ib_map = { 0 => 'NO', 10 => 'SDR', 20 => 'DDR', 40 => 'QDR', 56 => 'FDR', 100 => 'EDR', 200 => 'HDR' }
h['ib_count'] = ni_mountable.length
h['ib_rate'] = ni_mountable.length > 0 ? ni_fastest['rate'] / 1_000_000_000 : 0
Loading