User Tools

Site Tools


nndocs:srp

This is an old revision of the document!


targetcli-fb

  • it needs to be turned on in the kernel. drivers → Infiniband → SRP
  • turn on both target and initiator please
  • in targetcli, /srpt is the relevant path
  • targets are formatted like ib.fe80000000000000f4521403002c18b1
  • idk how you get those numbers except to examine an ipoib link, such as:
5: ib0: <...> mtu 2044 ...
    link/infiniband 80:00:02:18:fe:80:00:00:00:00:00:00:f4:52:14:03:00:2c:18:b1
    brd             00:ff:ff:ff:ff:12:40:1b:ff:ff:00:00:00:00:00:00:ff:ff:ff:ff

Now strip the first 4 bytes off (they change anyway) and remove the :'s

/srpt> ib.fe800000000000005849560e53b70b01/acls create ib.fe800000000000005849560e59150301
Created Node ACL for ib.fe800000000000005849560e59150301
Created mapped LUN 0.

Dependencies

apt install srptools

Login fails

shark (initiator):

  # srp_daemon -v -c -p 1 -o

from dmesg:

 [74794.509035] scsi host11: ib_srp: REJ received
 [74794.509038] scsi host11: ib_srp: SRP LOGIN from fe80:0000:0000:0000:5849:560e:5915:0301 to fe80:0000:0000:0000:5849:560e:53b7:0b09 REJECTED, reason 0x00010001
 [74794.509048] scsi host11: ib_srp: Connection 0/12 to fe80:0000:0000:0000:5849:560e:53b7:0b09 failed

southpark (target) dmesg:

 [4483481.918835] ib_srpt Received SRP_LOGIN_REQ with i_port_id 5849:560e:53b7:0b09:5849:560e:5915:0301, t_port_id 5849:560e:53b7:0b01:5849:560e:53b7:0b01 and it_iu_len 8260 on port 1 (guid=fe80:0000:0000:0000:5849:560e:53b7:0b09); pkey 0xb068
 [4483481.945664] ib_srpt rejected SRP_LOGIN_REQ because target port ibp33s0f1_1 has not yet been enabled
 [4483481.959142] ib_srpt Rejecting login with reason 0x10001

“port has not yet been enabled” according to the source code, checks the HCA port itself if its enabled. I think the value isn't being curried correctly somewhere, because:

[root]@[southpark][/sys/kernel/config/target/srpt/0xfe800000000000005849560e53b70b01/tpgt_1]# cat enable 
1
nndocs/srp.1741540630.txt.gz · Last modified: 2025/03/09 17:17 by naptastic