RHEL5.8 下Infiniband驱动安装过程笔记。
1 下载驱动
地址:?product_family=26&mtag=linux_sw_drivers
根据操作系统版本进行驱动选择,建议使用ISO格式驱动包。
备注:RHEL5及以前版本选择1.5.3系列驱动,,RHEL6及以后版本选择2.0及以上系列驱动。
2 驱动安装
2.1 将下载好的驱动传到服务器上,挂载到/public/ofed目录。
[root@node33 sourcecode]#mount -o loop MLNX_OFED_LINUX-1.5.3-4.0.42-rhel5.8-x86_64.iso /public/ofed/
[root@node33 sourcecode]# cd
[root@node33 ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda3 117G 9.8G 101G 9% /
/dev/sda1 494M 17M 452M 4% /boot
tmpfs 5.9G 0 5.9G 0% /dev/shm
/tftpboot/rhel.iso 3.9G 3.9G 0 100% /tftpboot/iso
/public/sourcecode/MLNX_OFED_LINUX-1.5.3-4.0.42-rhel5.8-x86_64.iso
267M 267M 0 100% /public/ofed
[root@node33 ~]#
2.2 执行安装命令,开始软件包安装。
[root@node33 ~]# /public/ofed/mlnxofedinstall -y
Usage:/public/ofed/mlnxofedinstall [OPTIONS]
Options
-c|–config <packages config_file> Example of the configurationfile
can be found under docs
-n|–net <network config_file> Example of the networkconfiguration file
canbe found under docs
-k|–kernel-version <kernel version> Use provided kernel versioninstead of ‘uname -r’
-p|–print-available Printavailable packages for current platform
Andcreate corresponding ofed.conf file
–without-32bit Skip32-bit libraries installation
–without-depcheck SkipDistro’s libraries check
–without-fw-update Skip firmware update
–fw-update-only Updatefirmware. Skip driver installation
–force-fw-update Forcefirmware update
–force Forceinstallation
–all|–hpc|–basic|–msm Install all, hpc, basic or Mellanox Subnetmanager packages
correspondingly
–vma|–vma-vpi Installpackages required by VMA to support VPI
–vma-eth Install packages required by VMA towork over Ethernet
-v|-vv|-vvv Setverbosity level
–umad-dev-rw Grantnon root users read/write permission for umad devices instead of default
–hugepages-overcommit Setting 80% of MAX_MEMORY as overcommitfor huge page allocation
–pfc <0|bitmask> Priority based Flow Control policy on TX and RX [7:0].
Perpriority bit mask (uint). Default 0.
-q Setquiet – no messages will be printed
[root@node33 ~]# echo y |/public/ofed/mlnxofedinstall –basic –msm –umad-dev-rw –hugepages-overcommit
This program will install the MLNX_OFED_LINUX packageon your machine.
Note that all other Mellanox, OEM, OFED, orDistribution IB packages will be removed.
Do you want to continue?[y/N]:
Starting MLNX_OFED_LINUX-1.5.3-4.0.42 installation…
Installing mlnx-ofa_kernel RPM
Preparing… ##################################################
mlnx-ofa_kernel ##################################################
Installing kmod-mlnx-ofa_kernel RPM
Preparing… ##################################################
kmod-mlnx-ofa_kernel ##################################################
Installing kmod-mlnx-ofa_kernel-xen RPM
Preparing… ##################################################
kmod-mlnx-ofa_kernel-xen ##################################################
Installing kernel-mft RPM
Preparing… ##################################################
kernel-mft ##################################################
Installing user level RPMs:
Preparing… ##################################################
mlnxofed-docs ##################################################
Preparing… ##################################################
ofed-scripts ##################################################
Preparing… ##################################################
libibverbs ##################################################
Preparing… ##################################################
libibverbs ##################################################
Preparing… ##################################################
libibverbs-utils ##################################################
Preparing… ##################################################
libmthca ##################################################
Preparing… ##################################################
libmthca ##################################################
Preparing… ##################################################
libmverbs ##################################################
Preparing… ##################################################
libmverbs ##################################################
Preparing… ##################################################
libmlx4 ##################################################
Preparing… ##################################################
libmlx4 ##################################################
Preparing… ##################################################
libcxgb3 ##################################################
Preparing… ##################################################
libcxgb3 ##################################################
Preparing… ##################################################
libnes ##################################################
Preparing… ##################################################
libnes ##################################################
Preparing… ##################################################
libipathverbs ##################################################
Preparing… ##################################################
libipathverbs ##################################################
Preparing… ##################################################
librdmacm ##################################################
Preparing… ##################################################
librdmacm ##################################################
Preparing… ##################################################
librdmacm-utils ##################################################
Preparing… ##################################################
mstflint ##################################################
Preparing… ##################################################
libibumad ##################################################
Preparing… ##################################################
libibumad ##################################################
Preparing… ##################################################
libibmad ##################################################
Preparing… ##################################################
libibmad ##################################################
Preparing… ##################################################
mft ##################################################
Preparing… ##################################################
opensm-libs ##################################################
Preparing… ##################################################
opensm-libs ##################################################
Preparing… ##################################################
infiniband-diags ##################################################
Preparing… ##################################################
opensm ##################################################
Preparing… ##################################################
ibutils ##################################################
Device (06:00.0):
06:00.0InfiniBand: Mellanox Technologies MT26428 [ConnectX VPI PCIe 2.0 5GT/s – IB QDR/ 10GigE] (rev b0)
LinkWidth: 8x
PCILink Speed: 2.5Gb/s
Installation finished successfully.
Programming HCA firmware for /dev/mst/mt26428_pci_cr0device
Running: mlxburn -d /dev/mst/mt26428_pci_cr0 -fw/public/ofed/firmware/fw-25408/2_9_1000/fw-ConnectX2-rel.mlx -dev_type25408 -no
-I- Querying device …
-I- Using auto detected configuration file:/public/ofed/firmware/fw-25408/2_9_1000/MHQH19B-XTR_A1-A3.ini (PSID =MT_0D90110009)
-I- Generating image …
Current FW version on flash: 2.7.626
New FW version: 2.9.1000
Burning FW image without signatures – OK
Restoring signature – OK
-I- Image burn completed successfully.
Configuring /etc/security/limits.conf.
Please reboot your system for the changes to takeeffect.
[root@node33 ~]#
备注:安装可选all、hpc、basic、msm四种方式。建议使用basic标准模式。管理节点需要安装msm和basic两种模式!!!安装过程中会强制刷新HCA卡固件,非独立HCA卡请严格注意固件版本!!!
2.3 配置IB网卡IP地址
[root@node33 ~]# cat <<EOF >> /etc/sysconfig/network-scripts/ifcfg-ib0
>DEVICE=ib0
>BOOTPROTO=none
>ONBOOT=yes
>NETMASK=255.255.255.0
>IPADDR=12.12.12.3
> EOF
[root@node33 ~]#
[root@node33 ~]# cat/etc/sysconfig/network-scripts/ifcfg-ib0
DEVICE=ib0
BOOTPROTO=none
ONBOOT=yes
NETMASK=255.255.255.0
IPADDR=12.12.12.33
[root@node33 ~]#
2.4 启动IB服务
[root@node33 ~]# chkconfig–list | grep open
openibd 0:off 1:off 2:on 3:on 4:on 5:on 6:off
opensmd 0:off 1:off 2:off 3:on 4:on 5:on 6:off
[root@node33 ~]# /etc/init.d/openibdrestart
Unloading HCA driver: [ OK ]
Loading HCA driver and Access Layer: [ OK ]
Setting up InfiniBand network interfaces:
Bringing up interface ib0: [ OK ]
Setting up service network . . . [ done ]
[root@node33 ~]# /etc/init.d/opensmdrestart
Stopping IB Subnet Manager. [FAILED]
Starting IB Subnet Manager. [ OK ]
[root@node33 ~]# ibstat
CA ‘mlx4_0’
CAtype: MT26428
Numberof ports: 1
Firmwareversion: 2.9.1000
Hardwareversion: b0
NodeGUID: 0x0002c903000cc00e
Systemimage GUID: 0x0002c903000cc011
Port 1:
State:Active
Physicalstate: LinkUp
Rate:40
Baselid: 1
LMC:0
SMlid: 1
Capabilitymask: 0x0251086a
PortGUID: 0x0002c903000cc00f
Linklayer: InfiniBand
[root@node33 ~]#
备注:管理节点需要先启动openibd,后启动opensmd。计算节点只需要启动openibd。配置完成后注意通过ibstat检查速率和链路状态。
3 卸载IB驱动
[root@node33 ~]#echo y | /public/ofed.uninstall.sh
This program will uninstall allMLNX_OFED_LINUX-1.5.3-4.0.42 packages on your machine.
Do you want to continue?[y/N]:y
三亚呀——赴一个蓝天碧海。只是微笑地固执自己的坚持,