cd ChelsioUwire-3.9.0.0
make iscsi_pdu_initiator_install
rmmod csiostor cxgb4i cxgbit iw_cxgb4 chcr cxgb4vf cxgb4 libcxgbi libcxgb
modprobe cxgb4i
iscsiadm -m iface
#创建文件/etc/iscsi/ifaces/cxgb4i.xx:xx:xx:xx:xx:xx
iface.iscsi_ifacename = cxgb4i.00:07:43:13:bf:50
iface.hwaddress = 00:07:43:13:bf:50
iface.transport_name = cxgb4i
iface.net_ifacename = enp2s0f4
iface.ipaddress = 182.168.2.50
确保/var/lib/iscsi/ifaces存在cxgb4i.00:07:43:13:bf:50
#启动iscsi
iscsid
#发现target
iscsiadm -m discovery -t st -p 182.168.2.49:3260 -I cxgb4i.00:07:43:13:bf:50
#登录
iscsiadm -m node -p 182.168.2.49:3260 -I cxgb4i.00:07:43:13:bf:50 -l
#登出
iscsiadm -m node -p 182.168.2.49:3260 -I cxgb4i.00:07:43:13:bf:50 -u
#卸载iscsi
rmmod cxgb4i
rmmod libcxgbi
原文地址:https://www.cnblogs.com/niezhongle/p/11062559.html