What does readahead in mongodb stands for? -


i getting warning on mongodb,

warning: readahead /data set 1024kb suggest setting 256kb (512 sectors) or less http://dochub.mongodb.org/core/readahead 

when querying this, every link suggests setting readahead value less figure , how set it?

i know setting lesser value let me rid of warning, more interested in readahead stands for? repercussions if set higher value?

read-ahead kernel feature, works @ block device level , global (is not process-dependend). technique employed in attempt improve file reading performance. if kernel has reason believe particular file being read sequentially, attempt read blocks file memory before application requests them. when readahead works, speeds system's throughput, since reading application not have wait requests. when readahead fails, instead, generates useless i/o , occupies memory pages needed other purpose. (https://lwn.net/articles/155510/)

here's more in depth explanation -> http://man7.org/linux/man-pages/man2/readahead.2.html

in order fix ensure readahead settings block devices store database files appropriate. random access use patterns, set low readahead values. readahead of 32 (16 kb) works well.

in linux:

  1. login root -> su -

  2. run sudo blockdev --report readahead settings

  3. run sudo blockdev --setra <value> <device> change readahead settings


Comments

Popular posts from this blog

Hatching array of circles in AutoCAD using c# -

ios - UITEXTFIELD InputView Uipicker not working in swift -

Python Pig Latin Translator -