1STAFD.CONF(5) STAFD.CONF(5)
2
3
4
6 stafd.conf - stafd(8) configuration file
7
9 /etc/stas/stafd.conf
10
12 When stafd(8) starts up, it reads its configuration from stafd.conf.
13
15 stafd.conf is a plain text file divided into sections, with
16 configuration entries in the style key=value. Spaces immediately before
17 or after the = are ignored. Empty lines are ignored as well as lines
18 starting with #, which may be used for commenting.
19
21 [Global] section
22 The following options are available in the [Global] section:
23
24 tron=
25 Trace ON. Takes a boolean argument. If true, enables full code
26 tracing. The trace will be displayed in the system log such as
27 systemd's journal. Defaults to false.
28
29 hdr-digest=
30 Enable Protocol Data Unit (PDU) Header Digest. Takes a boolean
31 argument. NVMe/TCP facilitates an optional PDU Header digest.
32 Digests are calculated using the CRC32C algorithm. If true, Header
33 Digests are inserted in PDUs and checked for errors. Defaults to
34 false.
35
36 data-digest=
37 Enable Protocol Data Unit (PDU) Data Digest. Takes a boolean
38 argument. NVMe/TCP facilitates an optional PDU Data digest. Digests
39 are calculated using the CRC32C algorithm. If true, Data Digests
40 are inserted in PDUs and checked for errors. Defaults to false.
41
42 kato=
43 Keep Alive Timeout (KATO) in seconds. Takes an unsigned integer.
44 This field specifies the timeout value for the Keep Alive feature
45 in seconds. Defaults to 30 seconds for Discovery Controller
46 connections and 120 seconds for I/O Controller connections.
47
48 ip-family=
49 Takes a string argument. With this you can specify whether IPv4,
50 IPv6, or both are supported when connecting to a Controller.
51 Connections will not be attempted to IP addresses (whether
52 discovered or manually configured with controller=) disabled by
53 this option. If an invalid value is entered, then the default (see
54 below) will apply.
55
56 Choices are ipv4, ipv6, or ipv4+ipv6.
57
58 Defaults to ipv4+ipv6.
59
60 persistent-connections=
61 Takes a boolean argument. Whether connections to Discovery
62 Controllers (DC) are persistent. When true, connections initiated
63 by stafd will persists even when stafd is stopped. When false,
64 stafd will disconnect from all DCs it is connected to on exit.
65 Defaults to false.
66
67 ignore-iface=
68 Takes a boolean argument. This option controls how connections with
69 Discovery Controllers (DC) are made.
70
71 DCs are automatically discovered using DNS-SD/mDNS. mDNS provides
72 the DC's IP address and the interface on which the DC was
73 discovered.
74
75 There is no guarantee that there will be a route to reach that DC.
76 However, we can use the socket option SO_BINDTODEVICE to force the
77 connection to be made on a specific interface instead of letting
78 the routing tables decide where to make the connection.
79
80 This option determines whether stafd will use SO_BINDTODEVICE to
81 force connections on an interface or just rely on the routing
82 tables. The default is to use SO_BINDTODEVICE, in other words,
83 stafd does not ignore the interface by default.
84
85 Defaults to false.
86
87 pleo=
88 Port Local Entries Only. Takes a string argument enabled or
89 disabled. This option is sent in the LSP field (Log SPecific) of
90 the Get Discovery Log Page (DLP) command. It is used by stafd to
91 tell Discovery Controllers (DC) whether the response to a Get DLP
92 command should contain all the NVM subsystems or only those
93 reachable by the host on the interface where the Get DLP command
94 was issued by the host.
95
96 This parameter was introduced in TP8010. When pleo=enabled, then
97 the DC shall return records for only NVM subsystem ports that are
98 presented through the same NVM subsystem port that received the Get
99 Log Page command. When pleo=disabled, then the DC may return all
100 the NVM subsystem ports that it holds, even those that can only be
101 reached on NVM subsystem ports that did not receive the Get Log
102 Page command. In other words, the host may not even be able to
103 reach those subsystems.
104
105 Defaults to enabled.
106
107 [Service Discovery] section
108 The following options are available in the [Service Discovery] section:
109
110 zeroconf=
111 Enable zeroconf provisioning using DNS-SD/mDNS. Takes a string
112 argument enabled or disabled.
113
114 When enabled, the default, stafd makes a request with the Avahi
115 daemon to locate Discovery Controllers using DNS-SD/mDNS.
116
117 Discovery Controllers that support zeroconf advertize themselves
118 over mDNS with the service type _nvme-disc._tcp.
119
120 [Controllers] section
121 The following options are available in the [Controllers] section:
122
123 controller=
124 Controllers are specified with the controller option. This option
125 may be specified more than once to specify more than one
126 controller. The format is one line per Controller composed of a
127 series of fields separated by semi-colons as follows:
128
129 controller=transport=[trtype];traddr=[traddr];trsvcid=[trsvcid];host-traddr=[traddr],host-iface=[iface];nqn=[nqn]
130
131
132 Fields
133 transport=
134 This is a mandatory field that specifies the network fabric
135 being used for a NVMe-over-Fabrics network. Current trtype
136 values understood are:
137
138 Table 1. Transport type
139 ┌───────┬────────────────────────────┐
140 │trtype │ Definition │
141 ├───────┼────────────────────────────┤
142 │rdma │ The network fabric is an │
143 │ │ rdma network (RoCE, iWARP, │
144 │ │ Infiniband, basic rdma, │
145 │ │ etc) │
146 ├───────┼────────────────────────────┤
147 │fc │ The network fabric is a │
148 │ │ Fibre Channel network. │
149 ├───────┼────────────────────────────┤
150 │tcp │ The network fabric is a │
151 │ │ TCP/IP network. │
152 ├───────┼────────────────────────────┤
153 │loop │ Connect to a NVMe over │
154 │ │ Fabrics target on the │
155 │ │ local host │
156 └───────┴────────────────────────────┘
157
158 traddr=
159 This is a mandatory field that specifies the network
160 address of the Controller. For transports using IP
161 addressing (e.g. rdma) this should be an IP-based address
162 (ex. IPv4, IPv6). It could also be a resolvable host name
163 (e.g. localhost).
164
165 trsvcid=
166 This is an optional field that specifies the transport
167 service id. For transports using IP addressing (e.g. rdma,
168 tcp) this field is the port number.
169
170 Depending on the transport type, this field will default to
171 either 8009 or 4420 as follows.
172
173 UDP port 4420 and TCP port 4420 have been assigned by IANA
174 for use by NVMe over Fabrics. NVMe/RoCEv2 controllers use
175 UDP port 4420 by default. NVMe/iWARP controllers use TCP
176 port 4420 by default.
177
178 TCP port 4420 has been assigned for use by NVMe over
179 Fabrics and TCP port 8009 has been assigned by IANA for use
180 by NVMe over Fabrics discovery. TCP port 8009 is the
181 default TCP port for NVMe/TCP discovery controllers. There
182 is no default TCP port for NVMe/TCP I/O controllers, the
183 Transport Service Identifier (TRSVCID) field in the
184 Discovery Log Entry indicates the TCP port to use.
185
186 The TCP ports that may be used for NVMe/TCP I/O controllers
187 include TCP port 4420, and the Dynamic and/or Private TCP
188 ports (i.e., ports in the TCP port number range from 49152
189 to 65535). NVMe/TCP I/O controllers should not use TCP port
190 8009. TCP port 4420 shall not be used for both NVMe/iWARP
191 and NVMe/TCP at the same IP address on the same network.
192
193 Ref: IANA Service names port numbers[1]
194
195 nqn=
196 This field specifies the Controller's NVMe Qualified Name.
197
198 This field is mandatory for I/O Controllers, but is
199 optional for Discovery Controllers (DC). For the latter,
200 the NQN will default to the well-known DC NQN:
201 nqn.2014-08.org.nvmexpress.discovery if left undefined.
202
203 host-traddr=
204 This is an optional field that specifies the network
205 address used on the host to connect to the Controller. For
206 TCP, this sets the source address on the socket.
207
208 host-iface=
209 This is an optional field that specifies the network
210 interface used on the host to connect to the Controller
211 (e.g. IP eth1, enp2s0, enx78e7d1ea46da). This forces the
212 connection to be made on a specific interface instead of
213 letting the system decide.
214 Examples:
215
216 controller = transport=tcp;traddr=localhost;trsvcid=8009
217 controller = transport=tcp;traddr=2001:db8::370:7334;host-iface=enp0s8
218 controller = transport=fc;traddr=nn-0x204600a098cbcac6:pn-0x204700a098cbcac6
219
220
221
222 exclude=
223 Controllers that should be excluded can be specified with the
224 exclude= option. Using mDNS to automatically discover and connect
225 to controllers, can result in unintentional connections being made.
226 This keyword allows configuring the controllers that should not be
227 connected to.
228
229 The syntax is the same as for "controller", except that the
230 parameter host-traddr does not apply. Multiple exclude= keywords
231 may appear in the config file to specify more than 1 excluded
232 controller.
233
234 Note 1: A minimal match approach is used to eliminate unwanted
235 controllers. That is, you do not need to specify all the parameters
236 to identify a controller. Just specifying the host-iface, for
237 example, can be used to exclude all controllers on an interface.
238
239 Note 2: exclude= takes precedence over controller. A controller
240 specified by the controller keyword, can be eliminated by the
241 exclude= keyword.
242
243 Examples:
244
245 exclude = transport=tcp;traddr=fe80::2c6e:dee7:857:26bb # Eliminate a specific address
246 exclude = host-iface=enp0s8 # Eliminate everything on this interface
247
248
249
251 stafd(8)
252
254 1. IANA Service names port numbers
255 https://www.iana.org/assignments/service-names-port-numbers/service-names-port-numbers.xhtml?search=nvme
256
257
258
259nvme-stas 2.0-rc5 STAFD.CONF(5)