美文网首页
Windows下安装Memcached

Windows下安装Memcached

作者: 笑疯子 | 来源:发表于2018-07-23 14:06 被阅读22次

    因为官网并未提供Memcached的Windows安装包,故提供以下几个链接。

    32位系统 1.2.5版本:http://static.runoob.com/download/memcached-1.2.5-win32-bin.zip
    
    32位系统 1.2.6版本:http://static.runoob.com/download/memcached-1.2.6-win32-bin.zip
    
    32位系统 1.4.4版本:http://static.runoob.com/download/memcached-win32-1.4.4-14.zip
    
    64位系统 1.4.4版本:http://static.runoob.com/download/memcached-win64-1.4.4-14.zip
    
    32位系统 1.4.5版本:http://static.runoob.com/download/memcached-1.4.5-x86.zip
    
    64位系统 1.4.5版本:http://static.runoob.com/download/memcached-1.4.5-amd64.zip
    

    在1.4.5版本以前memcached 可以作为一个服务安装,但是1.4.5版本以后删除了该功能。

    memcached <1.4.5 版本安装

    1. 首先解压安装包到你想要的目录
    例如我解压到了E盘的develop下
    E:\develop\memcached
    
    1. 使用管理员权限运行命令:
    E:\develop\memcached\memcached.exe -d install
    
    1. 开启memcached服务
    E:\develop\memcached\memcached.exe -d start
    
    1. 关闭memcached服务
    E:\develop\memcached\memcached.exe -d stop
    

    memcached >= 1.4.5 版本安装

    1. 解压下载的安装包到指定目录
    2. memcached 不能作为服务来运行,需要使用任务计划中来开启一个普通的进程,在 window 启动时设置 memcached自动执行。
      我们使用管理员身份执行以下命令将 memcached 添加来任务计划表中:
    schtasks /create /sc onstart /tn memcached /tr "'E:\develop\memcached\memcached.exe' -m 512"
    
    注意:-m 512 意思是设置 memcached 最大的缓存配置为512M。
    
    1. 如果需要删除 memcached 的任务计划可以执行以下命令:
    schtasks /delete /tn memcached
    

    相关文章

      网友评论

          本文标题:Windows下安装Memcached

          本文链接:https://www.haomeiwen.com/subject/nlfjmftx.html