日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

redis启动警告解决

發布時間:2023/12/10 编程问答 23 豆豆
生活随笔 收集整理的這篇文章主要介紹了 redis启动警告解决 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

背景

最近在測試環境重啟后,redis啟動遇到了三個警告

第一個警告:The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
第二個警告:overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to/etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
第三個警告:you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix thisissue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain thesetting after a reboot. Redis must be restarted after THP is disabled.

解決方案

第一個警告

echo 'echo 511 > /proc/sys/net/core/somaxconn' >> /etc/rc.local
source /etc/rc.local

第二個警告

echo "vm.overcommit_memory = 1" >> /etc/sysctl.conf
sysctl -p

第三個警告

echo 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' >> /etc/rc.local
source /etc/rc.local

其實redis已經做到很詳細了,在報錯中已經給出了詳細的方案

?

詳細參考

報錯一: ??? http://blog.csdn.net/raintungli/article/details/37913765

報錯二:???? http://blog.csdn.net/whycold/article/details/21388455

報錯三:???? http://www.cnblogs.com/kerrycode/archive/2015/07/23/4670931.html

?

轉載于:https://www.cnblogs.com/Nedved/p/10472430.html

總結

以上是生活随笔為你收集整理的redis启动警告解决的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。