Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-04-04 Thread via GitHub
jpountz commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2036729679 Superseded by #13244. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-04-04 Thread via GitHub
jpountz closed pull request #13223: Recommend lowering the default mmap readahead. URL: https://github.com/apache/lucene/pull/13223 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comme

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-04-01 Thread via GitHub
mikemccand commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2030118399 The Linux source for readahead is quite wild (WARNING: GPL 2 code -- read at your own risk!): https://github.com/torvalds/linux/blob/master/mm/readahead.c -- This is an automated me

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-04-01 Thread via GitHub
mikemccand commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2030101331 I was trying to understand exactly how modern Linux kernels handle readahead, and uncovered [this interesting and enlightening summary](https://lwn.net/Articles/897786/) of a recent-i

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-29 Thread via GitHub
jpountz commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2026945157 > the alternative approach of using a MADV_RANDOM all the time for IOContext.READ I opened #13244 to show what this could look like. -- This is an automated message from the Apa

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-28 Thread via GitHub
jpountz commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2025770130 For reference, this change is based on similar observations as made on https://biriukov.dev/docs/page-cache/3-page-cache-and-basic-file-operations. `mmap` comes with a 128kB readahead wh

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-28 Thread via GitHub
rmuir commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2025529142 my thoughts here are that issues can be addressed by providing correct advice to `madvise`. IMO this should typically be `MADV_RANDOM` because accesses are in random order: even if "we" th

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-28 Thread via GitHub
uschindler commented on PR #13223: URL: https://github.com/apache/lucene/pull/13223#issuecomment-2024955655 I am also a bit skeptical why you need to modify the block device. If this would be a file system setting I can imagine it's useful. @rmuir this came from investigation by Wikim

Re: [PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-28 Thread via GitHub
rmuir commented on code in PR #13223: URL: https://github.com/apache/lucene/pull/13223#discussion_r1542723020 ## lucene/core/src/java/org/apache/lucene/store/MMapDirectory.java: ## @@ -38,6 +38,15 @@ * fragmented address space. If you get an {@link IOException} about mapping

[PR] Recommend lowering the default mmap readahead. [lucene]

2024-03-27 Thread via GitHub
jpountz opened a new pull request, #13223: URL: https://github.com/apache/lucene/pull/13223 This is a follow-up of a discussion on #13219. `mmap` has a higher readahead than regular `read()` operations by default, e.g. 128kB instead of 16kB on my Linux box. On indexes that exceed the size o