2013年11月28日木曜日

Redis に関する間違い情報

のようなものを最近目にしたものの、いちいちツッコむ類のものでもないしなということでここに書いておく。

その1
VMware がスポンサーだ

「今は」違う。コレ書いてる時点ではピボタル。Redis Sponsors をみるとわかる。ピボタルは VMware が噛んではいるので完全に違うというわけではない。

その2
バージョン 2.4 において、同時接続数がデフォルト 1024 だ

デフォルトは無制限。redis.conf はこのようになっている。By default there is no limit, blah-blah-blah..
################################### LIMITS ####################################
# Set the max number of connected clients at the same time. By default there
# is no limit, and it's up to the number of file descriptors the Redis process
# is able to open. The special value '0' means no limits.
# Once the limit is reached Redis will close all the new connections sending
# an error 'max number of clients reached'.
#
# maxclients 128



まぁこれから 2.4 を使うことはないから気にしなくてよい。

net.core.somaxconn や kern.ipc.somaxconn のこといってるのかな?と思ったけどありゃなにも変更してなければ 128 だったかな。小さすぎる。


一方、2.6 だと 10000 になっている。

################################### LIMITS ####################################
# Set the max number of connected clients at the same time. By default
# this limit is set to 10000 clients, however if the Redis server is not
# able ot configure the process file limit to allow for the specified limit
# the max number of allowed clients is set to the current file limit
# minus 32 (as Redis reserves a few file descriptors for internal uses).
#
# Once the limit is reached Redis will close all the new connections sending
# an error 'max number of clients reached'.
#
# maxclients 10000

さてついでに、こないだでた 2.8 系の最新 2.8.1 でみてみると..
################################### LIMITS ####################################
# Set the max number of connected clients at the same time. By default
# this limit is set to 10000 clients, however if the Redis server is not
# able to configure the process file limit to allow for the specified limit
# the max number of allowed clients is set to the current file limit
# minus 32 (as Redis reserves a few file descriptors for internal uses).
#
# Once the limit is reached Redis will close all the new connections sending
# an error 'max number of clients reached'.
#
# maxclients 10000


2.6 系とおなじ。

前、memcached や TokyoTyrant で setrlimit してるのと同じような箇所を Redis でも確認してたので、ついでにまたみてみよう。別エントリに書く。


0 件のコメント:

コメントを投稿