【Redis】設定相關
# 只支持本地
bind 127.0.0.1 -::1
protected-mode yes
# 要支援遠端存取註解 bind 127.0.0.1 -::1
# protected-mode no
# bind 127.0.0.1 -::1
protected-mode no
# 未完成三向交握+已完成三向交握上限
tcp-backlog 511
# Close the connection after a client is idle for N seconds (0 to disable)
# 0: 永不過期
timeout 0
# 檢測連線存在的間隔時間
tcp-keepalive 300
# 使用daemon啟動
daemonize yes
# pid檔案位置
# 如果指定了pid文件,Redis在啟動時會將其寫入指定位置,並在退出時刪除它。
# 當服務器以非守護模式運行時,如果在配置中未指定pid文件,則不會創建pid文件。當服務器以守護模式運行時,即使未指定,也將使用pid文件,默認為 "/var/run/redis.pid"。
# 創建pid文件是盡力而為的:如果Redis無法創建它,不會發生任何壞事,服務器將正常啟動和運行。
# 請注意,在現代Linux系統上,應改用 "/run/redis.pid",因為這更符合規範。
pidfile /var/run/redis_6379.pid
# log 級別
# debug (a lot of information, useful for development/testing)
# verbose (many rarely useful info, but not a mess like the debug level)
# notice (moderately verbose, what you want in production probably)
# warning (only very important / critical messages are logged)
loglevel notice