Needs clarification on QueryNode Disk Usage #35159
-
I am using milvus 2.4.0. And the following is QueryNode configuration. I would like to know if there would be significant local disk consumption in this QueryNode when I am not using any Disk Indexes. The reason for that question was that I was getting a low on ephemeral storage error with this config and I couldn't see anything being stored in the localstorage path (/var/lib/milvus/data/) inside the QueryNode. (Verified using "du" and "ls -alrt" commands) Then I tried enabling mmap and ran my script which did collection creation, insertion, load, search etc. Now I observed lot of directories being created at /var/lib/milvus/data/mmap but most of them were empty or had a directory which was empty. Why is it like that ? queryNode:
cache:
enabled: true
memoryLimit: 2147483648 # 2 GB, 2 * 1024 *1024 *1024
dataSync:
flowGraph:
maxQueueLength: 16 # Maximum length of task queue in flowgraph
maxParallelism: 1024 # Maximum number of tasks executed in parallel in the flowgraph
stats:
publishInterval: 1000 # Interval for querynode to report node information (milliseconds)
segcore:
cgoPoolSizeRatio: 2.0 # cgo pool size ratio to max read concurrency
knowhereThreadPoolNumRatio: 4
# Use more threads to make better use of SSD throughput in disk index.
# This parameter is only useful when enable-disk = true.
# And this value should be a number greater than 1 and less than 32.
chunkRows: 1024 # The number of vectors in a chunk.
growing: # growing a vector index for growing segment to accelerate search
enableIndex: true
nlist: 128 # growing segment index nlist
nprobe: 16 # nprobe to search growing segment, based on your accuracy requirement, must smaller than nlist
loadMemoryUsageFactor: 1 # The multiply factor of calculating the memory usage while loading segments
enableDisk: false # enable querynode load disk index, and search on disk index
maxDiskUsagePercentage: 95
grouping:
enabled: true
maxNQ: 1000
topKMergeRatio: 20
scheduler:
receiveChanSize: 10240
unsolvedQueueSize: 10240
# maxReadConcurrentRatio is the concurrency ratio of read task (search task and query task).
# Max read concurrency would be the value of runtime.NumCPU * maxReadConcurrentRatio.
# It defaults to 2.0, which means max read concurrency would be the value of runtime.NumCPU * 2.
# Max read concurrency must greater than or equal to 1, and less than or equal to runtime.NumCPU * 100.
# (0, 100]
maxReadConcurrentRatio: 1
cpuRatio: 10 # ratio used to estimate read task cpu usage.
maxTimestampLag: 86400
# read task schedule policy: fifo(by default), user-task-polling.
scheduleReadPolicy:
# fifo: A FIFO queue support the schedule.
# user-task-polling:
# The user's tasks will be polled one by one and scheduled.
# Scheduling is fair on task granularity.
# The policy is based on the username for authentication.
# And an empty username is considered the same user.
# When there are no multi-users, the policy decay into FIFO
name: fifo
maxPendingTask: 10240
# user-task-polling configure:
taskQueueExpire: 60 # 1 min by default, expire time of inner user task queue since queue is empty.
enableCrossUserGrouping: false # false by default Enable Cross user grouping when using user-task-polling policy. (close it if task of any user can not merge others).
maxPendingTaskPerUser: 1024 # 50 by default, max pending task in scheduler per user. |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 9 replies
-
Read this discussion: #33621 |
Beta Was this translation helpful? Give feedback.
-
Thanks @yhmo this clarified how QueryNode uses disk when using mmap. I had some additional doubts :
|
Beta Was this translation helpful? Give feedback.
-
@yhmo We have increased ephemeral storage to 30GB but still pods are getting crashed with limit exceeds. below is the error for your reference. because of this nodes are going in Evicted and we can not increase it further as total limit on node is 50GB only. "Warning Evicted 10m (x7 over 14m) kubelet Pod ephemeral local storage usage exceeds the total limit of containers 30Gi." Why query node writing so much local data and can we set some buffer setting to ignore local storage rather if this can be processed in memory? |
Beta Was this translation helpful? Give feedback.
Read this discussion: #33621
The directories are empty but the data is still on disk. The file is invisible since unlink() is called after mmap.
Our engineer might make some changes to keep the files visible in future.