| 5c59cec2 | 09-Jul-2025 |
John Baldwin <jhb@FreeBSD.org> |
nvmf: Auto-reconnect periodically after a disconnect
Use a timer in the nvmf(4) driver to periodically trigger a devctl "RECONNECT" notification. A trigger in the /etc/devd/nvmf.conf file invokes "
nvmf: Auto-reconnect periodically after a disconnect
Use a timer in the nvmf(4) driver to periodically trigger a devctl "RECONNECT" notification. A trigger in the /etc/devd/nvmf.conf file invokes "nvmecontrol reconnect nvmeX" upon each notification. This differs from iSCSI which uses a dedicated daemon (iscsid(8)) to wait inside a custom ioctl for an iSCSI initiator event to occur, but I think this design might be simpler.
Similar to nvme-cli, the interval between reconnection attempts is specified in seconds by the --reconnect-delay argument to the connect and reconnect commands. Note that nvme-cli uses -c for short letter of this command, but that was already taken so nvmecontrol uses -r. The default is 10 seconds to match Linux.
In addition, a second timeout can be used to force a full detach of a disconnected the nvmeX device after the controller loss timeout expires. The timeout for this is specified in seconds by the --ctrl-loss-tmo/-l options (identical to nvme-cli). The default is 600 seconds.
Either of these timers can be disabled by setting the timer to 0. In that case, the associated action (devctl notifications or full detach) will not occur after a disconnect.
Note that this adds a dedicated taskqueue for nvmf tasks instead of using taskqueue_thread as the controller loss task could deadlock waiting for the completion of other tasks queued to taskqueue_thread. (Specifically, tearing down the CAM SIM can trigger destroy_dev_sched_cb() and waits for the callback to run, but the callback is scheduled to run in a task on taskqueue_thread. Possibly, destroy_dev_sched should be using a dedicated taskqueue.)
Reviewed by: imp (earlier version) Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D50222
show more ...
|
| 9ad1589c | 08-Jul-2025 |
John Baldwin <jhb@FreeBSD.org> |
devd.conf.5: Use a tag list block for NVMe SMART errors
groff doesn't seem to handle nested column list blocks correctly for postscript and HTML output causing the subsequent nvme event to be indent
devd.conf.5: Use a tag list block for NVMe SMART errors
groff doesn't seem to handle nested column list blocks correctly for postscript and HTML output causing the subsequent nvme event to be indented incorrectly. Using a tag list block works around this.
Sponsored by: Chelsio Communications
show more ...
|
| b00d9fa1 | 08-Jul-2025 |
John Baldwin <jhb@FreeBSD.org> |
devd.conf.5: Expand the width of various columns
Using upper case for column width templates avoids overfull columns when using groff to generate a postscript version of the manpage but doesn't affe
devd.conf.5: Expand the width of various columns
Using upper case for column width templates avoids overfull columns when using groff to generate a postscript version of the manpage but doesn't affect the terminal version.
Use a wider default column (8 characters) for the "Type" column and use wider widths for tables with longer event types.
In the terminal, man(1) forces a line break after overfull column items, but in the postscript and HTML versions the column just overflows into the adjacent column without any separation.
Sponsored by: Chelsio Communications
show more ...
|