<div dir="ltr">On 22 Jun 2020 "guru.novice" wrote:<div>Hi, all<br>We setup up a cluster use mlx4 and mlx5 driver mixed?all things goes well.<br>Later I find something in wiki<br><a href="http://wiki.lustre.org/Infiniband_Configuration_Howto">http://wiki.lustre.org/Infiniband_Configuration_Howto</a> and<br><a href="http://lists.onebuilding.org/pipermail/lustre-devel-lustre.org/2016-May/003842.html">http://lists.onebuilding.org/pipermail/lustre-devel-lustre.org/2016-May/003842.html</a><br>which was<br>last edited on 2016.<br>So do i need to change lnet configuration described in this page ?<br>Or the problem has been resolved in new version (like 2.12.x) ?<br>Anymore where can i find more details ?<br><br>Any suggestions would be appreciated.<br>Thanks?<br></div><div><br></div><div>Hello guru.novice,</div><div>Lustre 2.12.x has some nice LNet configuration abilities.  The old /etc/modprobe.d/ config files have been superceded by /etc/lnet.conf.   An install of Lustre 2.12.x provides a sample of this file (with the lines commented out).  Our experience has shown that not all lines are necessary; edit to suit.  </div><div><br></div><div>The Lustre 2.12.x has Multi-Rail (MR) on by default so Lustre will attempt to automatically find active and viable LNet paths to use.  This should have no issue with your mlx4/5 mix environment; we have some mixed IB and eth that work. To explicitly use MR one may set "Multi-Rail: true" in the "peer" NID section of the /etc/lnet.conf file.  But that was not necessary for us.  We used a simple /etc/lnet.conf for MR systems:</div><div>File stub: /etc/lnet.conf</div><div>net:</div><div>   - net type: o2ib0</div><div>     local NI(s):</div><div>        - interfaces:</div><div>             0: ib0</div><div>  - net type: o2ib777</div><div>     local NI(s):</div><div>        - interfaces:</div><div>             0: ib0:1</div><div>This allowed LNet to use any NID o2ib0 and o2ib777.</div><div><br></div><div>Whatever is placed in the /etc/lnet.conf file is loaded into the kernel modules used via the Lustre starting mechanism (CentOS uses /usr/lib/systemd/system).  Because we are choosing _not_ to use MR on a different box, we explicitly defined the available routes in /etc/lnet.conf using the lines:</div><div>route:</div><div>   - net: tcp</div><div>     gateway: 10.10.10.101@o2ib11111</div><div>   - net: tcp</div><div>     gateway: 10.10.10.102@o2ib1111</div><div>And so on up to 10.10.10.116@o2ib1111</div><div><br></div><div> In CentOS7, /usr/lib/systemd/system/lnet.service file is reproduced below.  (details: lustre-2.12.4-1 with Mellanox OFED version 4.7-1.0.0.1 and  kernel 3.10.957.27.2.el7)</div><div>File lnet.service:</div><div>[unit]</div><div>Description=lnet management</div><div>Requires=network-online.target</div><div>After=network-online.target openibd.service rdma.service opa.service</div><div>ConditionsPathExists=!/proc/sys/lnet/</div><div><br></div><div>[Service]</div><div>Type=oneshot</div><div>RemainAfterExit=true</div><div>ExecStart=/sbin/modprobe lnet</div><div>ExecStart=/usr/sbin/lnetctl lnet configure</div><div>ExecStart=/usr/sbin/lnetctl set discover 0   <--Do NOT use this line if you want MR function</div><div>ExecStart=/usr/sbin/lnetctl import /etc/lnet.conf  <--The file with router, credit and similar info</div><div>ExecStart=/usr/sbin/lnetctl peer add --nid 10.10.10.[101-116]@o2ib11111 --non_mr  <--Omit non_rm if you want to use MR</div><div>ExecStop=/usr/sbin/lustre_rmmod ptlrpc</div><div>ExecStop=/usr/sbin/lnetctl lnet unconfigure</div><div>ExecStop=/usr/sbin/lustre_rmmod libcfs ldiskfs</div><div><br></div><div>[Install]</div><div>WantedBy=multi-user.target</div><div><br></div><div>I hope this info can help you in the right direction.</div><div><br></div><div>Cheers,</div><div>megan</div><div>PS. [I am willing to add/contribute to the <a href="http://wiki.lustre.org/Infiniband_Configuration_Howto">http://wiki.lustre.org/Infiniband_Configuration_Howto</a> but I think my account for wiki editing has expired (at least the one I thought I had did not work).</div><div>Our site had issues with Multi-Rail "not socially distancing appropriately" from other LNet networks so in our particular case we disabled MR.  (An entirely different experience.) ]</div></div>