A good setting to use is four times the number of megabytes of system memory. For example, if you're running on a system with 128 gigabytes of memory, then calculate (128*1024=131072 megabytes) times 4, which is 524288.

  1. Sign on as root user.
  2. Add the line vm.max_map_count = <megabytes> to the file /etc/sysctl.conf. For example:
    vm.max_map_count = 524288
  3. Restart the system to apply the change.
  4. Optional: If you need to tune performance further after setting the max_map_count parameter, do the following:
    1. Clone the existing performance profile.
    2. Run the tuned command.
    3. Add the line vm.max_map_count = <megabytes> to the file /usr/lib/tuned/profile-name/tuned.conf.
    4. To select the updated profile, run tuned-adm profile customized_profile.
    5. Restart the system to apply the changes.