【问题标题】:how do I start a memcache server [closed]如何启动内存缓存服务器 [关闭]
【发布时间】:2013-03-17 19:21:11
【问题描述】:

我正在安装内存缓存 manual .但是之后我得到了一个错误

echo "stats settings" | nc localhost 11211

错误

localhost [127.0.0.1] 11211 (?) : Connection refused

我找到了几个答案,但它们不起作用,例如

/etc/init.d/memcache start | restart

【问题讨论】:

  • /etc/init.d/memcache status 请问是哪个发行版?
  • bash: /etc/init.d/memcache: 没有这样的文件或目录。 Debian 6
  • ps aux | grep memcache root 10103 0.0 0.0 7548 872 pts/1 S+ 01:36 0:00 grep memcache. netstat -anp | grep LISTEN | grep 11211
  • 我认为这个问题可以移动..

标签: php apache memcached


【解决方案1】:

安装内存缓存:

apt-get install memcached

创建配置:

vim /etc/memcached.conf

[...]
# Specify which IP address to listen on. The default is to listen on all IP addresses
# This parameter is one of the only security measures that memcached has, so make sure
# it's listening on a firewalled interface.
# -l 12.34.56.78
-l 127.0.0.1
[...]

重启服务:

/etc/init.d/memcache restart

检查状态和监听端口:

netstat -tap | grep memcached

希望我能帮上忙。

【讨论】:

  • memcache 和 memcached 应用程序有什么不同吗?
  • memcached 是在内存中存储数据的服务,mamcache 是数据管理的客户端。
猜你喜欢
  • 1970-01-01
  • 2019-07-25
  • 2012-10-22
  • 2013-11-26
  • 1970-01-01
  • 2013-02-03
  • 1970-01-01
  • 2017-06-29
  • 2021-12-30
相关资源
最近更新 更多