Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
1–10 of 182 posts
Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#2Then there's the part with writes being delayed. Be prepared to deal with blocks not necessarily updating to disk in the order they were written to, and 10 seconds after the fact. This can make power failures cause inconsistencies.
Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#3Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#4Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#5Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#6Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#7maybe a stupid question but what is wrong with coffee and spicy food?
Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#8Memory-Mapped Files = access violations when a disk read fails. If you're not prepared to handle those, don't use memory-mapped files. (Access violation exceptions are the same thing that happens when you attempt to read a null pointer) Then there's the part with writes being delayed. Be prepared to deal with blocks not necessarily updating to disk in the order they were written to, and 10 seconds after the fact. Thi…
This is not specific to mmap -- regular old write() calls have the same behavior. You need to fsync() (or, with mmap, msync()) to guarantee data is on disk.
Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#9Re: Are You Sure You Want to Use MMAP in Your Database Management System? (2022)
#10Memory-Mapped Files = access violations when a disk read fails. If you're not prepared to handle those, don't use memory-mapped files. (Access violation exceptions are the same thing that happens when you attempt to read a null pointer) Then there's the part with writes being delayed. Be prepared to deal with blocks not necessarily updating to disk in the order they were written to, and 10 seconds after the fact. Thi…