zilliztech / starling

Other
41 stars 14 forks source link

MAX_EVENTS times Thread Number should not exceed aio-max-nr #1

Open PwzXxm opened 2 years ago

PwzXxm commented 2 years ago

DiskANN will assign an I/O context to each thread when doing io_setup(), MAX_EVENTS times the number of threads should not exceed the aio-max-nr in the system.

MAX_EVENTS is 1024 in DiskANN. The default aio-max-nr is 65536, so the maximum number of threads is 64.

To check the value of aio-max-nr on the system, run

sudo sysctl -a | grep fs.aio-max-nr

To change, run

sudo sysctl -w fs.aio-max-nr=X

Related Knowhere issue and fix https://github.com/milvus-io/knowhere/pull/379