The /proc/sys/vm/flush_mmap_pages Linux kernel parameter specifies whether or not memory-mapped file pages should be flushed to disk by kupdate while the memory map is active. Valid values for this parameter are 1 (enable memory mapping by kupdate) and 0 (disable memory mapping by kupdate). The default value for this parameter is 1. To configure this parameter, use echo [1 or 0] /proc/sys/vm/flush_mmap_pages. Setting this parameter to 0 does the following (quoting from the official documentation):
- kupdate will not flush dirty memory-mapped file pages as long as the memory map is active.
- All dirty file pages will be asynchronously flushed to disk only as soon as the memory map is deactivated.
All dirty file pages will be asynchronously flushed to disk only as soon as the memory map is deactivated. To enable memory mapping again, enter:
sysctl -w /proc/sys/vm/flush_mmap_pages=0
Add the following line to /etc/sysctl.conf:
sysctl -w /proc/sys/vm/flush_mmap_pages=1
echo 0 >/proc/sys/vm/flush_mmap_pages
No comments:
Post a Comment