cloudbase / wnbd

Windows Ceph RBD NBD driver
GNU Lesser General Public License v2.1
57 stars 26 forks source link

Increase IO limit #118

Closed petrutlucian94 closed 1 year ago

petrutlucian94 commented 1 year ago

Right now, we're limited to 255 requests per LUN and 1000 requests per adapter, which might be insufficient for large workloads.

We're going to make this configurable. Note that in order to be allowed to increase the limit, we need to support extended SRBs. This means that instead of accessing SRBs directly, we'll need to use the DDK helpers, which can handle both standard SRBs (SCSI_REQUEST_BLOCK) and extended SRBs (STORAGE_REQUEST_BLOCK).

Resetting the adapter is required in order for the new IO limits to be applied. For convenience, we're also adding a command that can be used to hard remove all attachments and then reset the adapter.

Sample:

PS C:\> wnbd-client.exe show rbd/test_4g_5
Connection info
...
MaxIOReqPerLun            : 255
MaxIOReqPerAdapter        : 1000

PS C:\> wnbd-client set-opt MaxIOReqPerLun 512 --persistent
PS C:\> wnbd-client set-opt MaxIOReqPerAdapter 8192 --persistent
PS C:\> Stop-Service ceph-rbd

PS C:\> wnbd-client.exe reset-adapter --hard-disconnect-mappings

PS C:\> Stop-Service ceph-rbd

PS C:\> wnbd-client.exe show rbd/test_4g_5
Connection info
...
MaxIOReqPerLun            : 512
MaxIOReqPerAdapter        : 8192