redis / redis-doc

Redis documentation source code for markdown and metadata files, conversion scripts, and so forth
Other
2.3k stars 1.73k forks source link

Redis administration #1937

Open loiclavoie opened 2 years ago

loiclavoie commented 2 years ago

The document in Redis Administration provides an incorrect command for disabling "transparent huge pages" on Linux Kernel.

It current states:

...This is accomplished with the following command: echo madvise > /sys/kernel/mm/transparent_hugepage/enabled.

The command should be echo never > /sys/kernel/mm/transparent_hugepage/enabled

Source redhat: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/performance_tuning_guide/sect-red_hat_enterprise_linux-performance_tuning_guide-configuring_transparent_huge_pages

juckerf commented 1 year ago

@banker during some research about the "disable THP" recommendation I stumbled upon this PR. In https://github.com/redis/redis-doc/pull/841 the recommendation was changed from never to madvise (based on this https://github.com/redis/redis/pull/4001/files) but now reverted in this PR - what's the recommendation now?

banker commented 1 year ago

@juckerf Sorry for the confusion here. @oranagra or @itamarhaber: can you advise?

oranagra commented 1 year ago

@banker, i agree, THP should be set to madvise (as is the default in some platforms), see https://github.com/redis/redis/pull/7771 maybe we can mention that it should be never if you wanna silence warnings in redis versions prior to 6.2.0 and 6.0.8.

@juckerf thanks for catching this!

juckerf commented 1 year ago

thanks for the clarification @banker & @oranagra

loiclavoie commented 1 year ago

My apology for the late response, but I no longer work at the company where I had this issue. Here what I remember from it: I installed redis on both Centos8 and RockyLinux (community editions of Redhat) and an issue arised when trying to configure the project. This issue was, from the search I did back then, fixed by setting the transparent_hugepage to never instead of madvise. I opened this ticket following the documentation found on the Redhat docs (link provided in the issue)

I don't have more information at the moment, it's been month since I had the original issue, so I currently cannot provide the logs concerning it.