tt作者的新产品 kc和kt是支持memcache协议的,不过要指明下共享库。
$ ktserver -plsv /usr/local/libexec/ktplugservmemc.so -plex 'port=2010'
The "-plsv" option specifies the path of a shared library. The "-plex" option specifies the configuration expression for the pluggable server. The memcached module understand the format such as "host=xxxx#port=xxx". The above command assigns that the pluggable server uses the port 2010, while the default port is 11211.
上面是原文,大致意思是说 -plsv 参数 表明了共享库的位置, -plex 是选项指定了可插拔服务器配置的表达。 port=2010 是只设置的通过访问memcache协议访问端口号,不可以和ktserver的 -port (默认是1978)设置成一样的,否则会出问题的,具体原因还待继续学习查究。设置完后可以用telnent去测试的。
$ telnet localhost 2010 Trying ::1... Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. set japan 0 0 5 tokyo STORED get japan VALUE japan 0 5 tokyo END quit
Connection closed by foreign host.
本文只是简单的整理,具体的请看原文。地址是:http://fallabs.com/mikio/tech-en/promenade.cgi?id=20