xref: /linux/Documentation/ABI/testing/sysfs-class-rtrs-client (revision 4f2c0a4acffbec01079c28f839422e64ddeff004)
1745b6a3dSJack WangWhat:		/sys/class/rtrs-client
2745b6a3dSJack WangDate:		Feb 2020
3745b6a3dSJack WangKernelVersion:	5.7
4745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
5745b6a3dSJack WangDescription:	When a user of RTRS API creates a new session, a directory entry with
6745b6a3dSJack Wang		the name of that session is created under /sys/class/rtrs-client/<session-name>/
7745b6a3dSJack Wang
8745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/add_path
9745b6a3dSJack WangDate:		Feb 2020
10745b6a3dSJack WangKernelVersion:	5.7
11745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
12745b6a3dSJack WangDescription:	RW, adds a new path (connection) to an existing session. Expected format is the
13002a9c2fSMauro Carvalho Chehab		following::
14745b6a3dSJack Wang
15745b6a3dSJack Wang		    <[source addr,]destination addr>
16745b6a3dSJack Wang		    *addr ::= [ ip:<ipv4|ipv6> | gid:<gid> ]
17745b6a3dSJack Wang
18745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/max_reconnect_attempts
19745b6a3dSJack WangDate:		Feb 2020
20745b6a3dSJack WangKernelVersion:	5.7
21745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
22745b6a3dSJack WangDescription:	Maximum number reconnect attempts the client should make before giving up
23745b6a3dSJack Wang		after connection breaks unexpectedly.
24745b6a3dSJack Wang
25745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/mp_policy
26745b6a3dSJack WangDate:		Feb 2020
27745b6a3dSJack WangKernelVersion:	5.7
28745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
29745b6a3dSJack WangDescription:	Multipath policy specifies which path should be selected on each IO:
30745b6a3dSJack Wang
31745b6a3dSJack Wang		round-robin (0):
32745b6a3dSJack Wang		    select path in per CPU round-robin manner.
33745b6a3dSJack Wang
34745b6a3dSJack Wang		min-inflight (1):
35745b6a3dSJack Wang		    select path with minimum inflights.
36745b6a3dSJack Wang
37abdeef3bSGioh Kim		min-latency (2):
38abdeef3bSGioh Kim		    select path with minimum latency.
39abdeef3bSGioh Kim
40745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/
41745b6a3dSJack WangDate:		Feb 2020
42745b6a3dSJack WangKernelVersion:	5.7
43745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
44745b6a3dSJack WangDescription:	Each path belonging to a given session is listed here by its source and
45745b6a3dSJack Wang		destination address. When a new path is added to a session by writing to
46745b6a3dSJack Wang		the "add_path" entry, a directory <src@dst> is created.
47745b6a3dSJack Wang
48745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/state
49745b6a3dSJack WangDate:		Feb 2020
50745b6a3dSJack WangKernelVersion:	5.7
51745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
52745b6a3dSJack WangDescription:	RO, Contains "connected" if the session is connected to the peer and fully
53745b6a3dSJack Wang		functional.  Otherwise the file contains "disconnected"
54745b6a3dSJack Wang
55745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/reconnect
56745b6a3dSJack WangDate:		Feb 2020
57745b6a3dSJack WangKernelVersion:	5.7
58745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
59745b6a3dSJack WangDescription:	Write "1" to the file in order to reconnect the path.
60745b6a3dSJack Wang		Operation is blocking and returns 0 if reconnect was successful.
61745b6a3dSJack Wang
62745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/disconnect
63745b6a3dSJack WangDate:		Feb 2020
64745b6a3dSJack WangKernelVersion:	5.7
65745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
66745b6a3dSJack WangDescription:	Write "1" to the file in order to disconnect the path.
67745b6a3dSJack Wang		Operation blocks until RTRS path is disconnected.
68745b6a3dSJack Wang
69745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/remove_path
70745b6a3dSJack WangDate:		Feb 2020
71745b6a3dSJack WangKernelVersion:	5.7
72745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
73745b6a3dSJack WangDescription:	Write "1" to the file in order to disconnected and remove the path
74745b6a3dSJack Wang		from the session.  Operation blocks until the path is disconnected
75745b6a3dSJack Wang		and removed from the session.
76745b6a3dSJack Wang
77745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/hca_name
78745b6a3dSJack WangDate:		Feb 2020
79745b6a3dSJack WangKernelVersion:	5.7
80745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
81*b18ee4a4SSlark XiaoDescription:	RO, Contains the name of HCA the connection established on.
82745b6a3dSJack Wang
83745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/hca_port
84745b6a3dSJack WangDate:		Feb 2020
85745b6a3dSJack WangKernelVersion:	5.7
86745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
87745b6a3dSJack WangDescription:	RO, Contains the port number of active port traffic is going through.
88745b6a3dSJack Wang
89745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/src_addr
90745b6a3dSJack WangDate:		Feb 2020
91745b6a3dSJack WangKernelVersion:	5.7
92745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
93745b6a3dSJack WangDescription:	RO, Contains the source address of the path
94745b6a3dSJack Wang
95745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/dst_addr
96745b6a3dSJack WangDate:		Feb 2020
97745b6a3dSJack WangKernelVersion:	5.7
98745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
99745b6a3dSJack WangDescription:	RO, Contains the destination address of the path
100745b6a3dSJack Wang
101abdeef3bSGioh KimWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/cur_latency
102abdeef3bSGioh KimDate:		Feb 2020
103abdeef3bSGioh KimKernelVersion:	5.7
104abdeef3bSGioh KimContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
105abdeef3bSGioh KimDescription:	RO, Contains the latency time calculated by the heart-beat messages.
106abdeef3bSGioh Kim		Whenever the client sends heart-beat message, it checks the time gap
107abdeef3bSGioh Kim		between sending the heart-beat message and receiving the ACK.
108abdeef3bSGioh Kim		This value can be changed regularly.
109abdeef3bSGioh Kim
110745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/stats/reset_all
111745b6a3dSJack WangDate:		Feb 2020
112745b6a3dSJack WangKernelVersion:	5.7
113745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
114745b6a3dSJack WangDescription:	RW, Read will return usage help, write 0 will clear all the statistics.
115745b6a3dSJack Wang
116745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/stats/cpu_migration
117745b6a3dSJack WangDate:		Feb 2020
118745b6a3dSJack WangKernelVersion:	5.7
119745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
120745b6a3dSJack WangDescription:	RTRS expects that each HCA IRQ is pinned to a separate CPU. If it's
121745b6a3dSJack Wang		not the case, the processing of an I/O response could be processed on a
122745b6a3dSJack Wang		different CPU than where it was originally submitted.  This file shows
123745b6a3dSJack Wang		how many interrupts where generated on a non expected CPU.
124002a9c2fSMauro Carvalho Chehab
125002a9c2fSMauro Carvalho Chehab		"from:"
126002a9c2fSMauro Carvalho Chehab		    is the CPU on which the IRQ was expected, but not generated.
127002a9c2fSMauro Carvalho Chehab		"to:"
128002a9c2fSMauro Carvalho Chehab		    is the CPU on which the IRQ was generated, but not expected.
129745b6a3dSJack Wang
130745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/stats/reconnects
131745b6a3dSJack WangDate:		Feb 2020
132745b6a3dSJack WangKernelVersion:	5.7
133745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
134745b6a3dSJack WangDescription:	Contains 2 unsigned int values, the first one records number of successful
135745b6a3dSJack Wang		reconnects in the path lifetime, the second one records number of failed
136745b6a3dSJack Wang		reconnects in the path lifetime.
137745b6a3dSJack Wang
138745b6a3dSJack WangWhat:		/sys/class/rtrs-client/<session-name>/paths/<src@dst>/stats/rdma
139745b6a3dSJack WangDate:		Feb 2020
140745b6a3dSJack WangKernelVersion:	5.7
141745b6a3dSJack WangContact:	Jack Wang <jinpu.wang@cloud.ionos.com> Danil Kipnis <danil.kipnis@cloud.ionos.com>
142745b6a3dSJack WangDescription:	Contains statistics regarding rdma operations and inflight operations.
143002a9c2fSMauro Carvalho Chehab		The output consists of 6 values::
144745b6a3dSJack Wang
145002a9c2fSMauro Carvalho Chehab		    <read-count> <read-total-size> <write-count> \
146002a9c2fSMauro Carvalho Chehab		    <write-total-size> <inflights> <failovered>
147