mac memcached

Memcached is an open-source high performance distributed memory object caching system. It is one of the most widely used cache mechanism used by some of the biggest websites like WordPress.com and LiveJournal.com.

Memcached是一个开源的高性能分布式内存对象缓存系统。 它是WordPress.com和LiveJournal.com等一些大型网站使用的最广泛使用的缓存机制之一。

It is also used by VBulletin software, for faster performance, that is one of the best software for Forums. It’s easy to install and there are so many client programs available on the Internet in different languages.

VBulletin软件也使用它来提高性能,这是论坛最好的软件之一。 它很容易安装,并且互联网上有许多可用不同语言的客户端程序。

Read: Memcached Java Client

阅读 : Memcached Java客户端

在Mac OS上安装Memcached (Install Memcached on Mac OS)

Memcached is a memory based caching mechanism and build using C language. To install memcached server on Mac OS, we need C library. Here I am assuming that C library is already present in the system. If it’s not, then you can download C compiler and install it or install XCode that installs GCC compiler with it.

Memcached是基于内存的缓存机制,并使用C语言进行构建。 要在Mac OS上安装memcached服务器,我们需要C库。 在这里,我假设系统中已经存在C库。 如果不是,则可以下载并编译C编译器,也可以安装XCode来安装GCC编译器 。

After that, you need to install the lib events library.

之后,您需要安装lib事件库。

Steps are;

步骤是;

$ curl -OL https://github.com/libevent/libevent/releases/download/release-2.1.8-stable/libevent-2.1.8-stable.tar.gz$ tar -xvf libevent-2.1.8-stable.tar.gz $ cd libevent-2.1.8-stable$ ./configure --prefix=/usr/local$ make$ sudo make install

Once libevents is installed then you can install Memcached server.

一旦安装了libevents,就可以安装Memcached服务器。

Steps are;

步骤是;

$ curl -O https://memcached.org/files/memcached-1.5.0.tar.gz$ tar -xvf memcached-1.5.0.tar.gz $ cd memcached-1.5.0$ ./configure --prefix=/usr/local$ make$ sudo make install
Password:
$

Now Memcached server is installed in your system. If the libevent library is not installed, configure command will give the following error.

现在,您的系统中已安装Memcached服务器。 如果未安装libevent库,则configure命令将出现以下错误。

$ ./configure --prefix=/usr/local
...
checking for libevent directory... configure: error: libevent is required.  You can get it from https://www.monkey.org/~provos/libevent/If it's already installed, specify its path using --with-libevent=/dir/pankaj:memcached-1.5.0 pankaj$

Memcached服务器在不同的端口上 (Memcached Server on Different Port)

By default, memcached server runs on TCP port 11211 and listens on UDP port 11211 and you can run multiple instances of memcached server from one installation.

默认情况下,memcached服务器在TCP端口11211上运行,并在UDP端口11211上侦听,并且您可以从一个安装中运行多个memcached服务器实例。

$memcached -d

Above command will start the Memcached server on TCP port 11211 and listens on UDP port 11211 as a daemon process.

上面的命令将在TCP端口11211上启动Memcached服务器,并在UDP端口11211上侦听作为守护进程。

$memcached -p 11111 -U 11111 -d

Above command will start the Memcached server on TCP port 11111 and listens on UDP port 11111 as a daemon process.

上面的命令将在TCP端口11111上启动Memcached服务器,并在UDP端口11111上侦听作为守护进程。

使用Telnet测试Memcached服务器 (Test Memcached Server using Telnet)

Next step is to use memcached telnet commands to test that it’s working fine.

下一步是使用memcached telnet命令测试它是否正常运行。

In some of the Linux systems, you also need to add the libevent library location in the path.

在某些Linux系统中,还需要在路径中添加libevent库的位置。

If you get following error in starting memcached server:

如果在启动memcached服务器时出现以下错误:

./memcached: error while loading shared libraries: libevent-1.4.so.2: cannot open shared object file: No such file or directory

./memcached:加载共享库时出错:libevent-1.4.so.2:无法打开共享库文件:没有这样的文件或目录

Then add following configuration in user profile (for example, .bash_profile or .profile)

然后在用户配置文件中添加以下配置(例如.bash_profile或.profile)

$export LD_LIBRARY_PATH= /usr/local/lib

Or, provide it’s path using --with-libevent option in configure command.

或者,在configure命令中使用--with-libevent选项提供其路径。

I have used the above steps to install Memcached server on Mac OS. If you face any issues, let me know. I will try to resolve them.

我已按照上述步骤在Mac OS上安装Memcached服务器。 如果您遇到任何问题,请告诉我。 我将尝试解决它们。

Happy Caching…

快乐缓存...

Further Reading: Install Memcached on CentOS and PHP integration

进一步阅读: 在CentOS和PHP集成上安装Memcached

References:

参考文献:

  • Memcached Download PageMemcached下载页面
  • Libevent WebsiteLibevent网站

翻译自: https://www.journaldev.com/1/install-memcached-mac

mac memcached

mac memcached_如何在Mac OS上安装Memcached Server相关推荐

  1. 如何在Windows即服务上安装Memcached Server

    In my earlier post, I explained how to install Memcached server on Mac OS. Today I will explain how ...

  2. 如何在Windows 10 上安装SQL Server 2000数据库?

    Win10本身是一个兼容性较好的操作系统,目前有很多人在咨询如何在Windows 10 上安装 SQL Server 2000数据库,都没有成功过.主要是卡在了安装过程中的mdac2.6 安装上,一直 ...

  3. 如何在 Windows 系统上安装 SQL Server 2022 Enterprise

    1.环境搭建: 视频教程:https://www.bilibili.com/video/BV1Ph4y187TY/?spm_id_from=333.999.0.0 2.执行SQL: -- 创建数据库 ...

  4. Windows OS上安装运行Apache Kafka教程

    Windows OS上安装运行Apache Kafka教程 下面是分步指南,教你如何在Windows OS上安装运行Apache Zookeeper和Apache Kafka. 简介 本文讲述了如何在 ...

  5. 服务器如何进入pe系统安装,如何在PE服务器上安装Windows2000Server.doc

    如何在PE服务器上安装Windows2000Server 如何在PE服务器上安装Windows2000 Server本文档介绍了在没有Dell OpenManage Server Assistant ...

  6. mac os maven_如何在Mac OS上安装Maven

    mac os maven 在Mac上安装Maven (Install Maven on Mac) Maven is the most widely used build and project dep ...

  7. mac安装rstudio_在Windows / Linux / Mac OS上安装R和RStudio入门

    mac安装rstudio 在Windows上安装R (Installing R on Windows) Go to r-project.org on your internet browser.在您的 ...

  8. 在 Mac OSX 版的 LispBox 环境上安装配置 SBCL 详细过程

    2019独角兽企业重金招聘Python工程师标准>>> 在 Mac OSX 版的 LispBox 环境上安装配置 SBCL 详细过程 今天在OSX版的 LispBox(使用CCL) ...

  9. 在arm架构的mac上安装sql server(m1芯片 or m2芯片)

    在arm架构的mac上安装sql server 由于Mac最新的芯片使用了arm架构的缘故 Sql server和Mac的兼容相当差,以至于无法在Mac的docker上启动 在m1芯片上很多方法试试还 ...

最新文章

  1. caj在线阅读_用翻译软件快速阅读大量英文文献
  2. 发布CodeBuild.Net代码自动生成器 V2008 2.01(Vs2008)和架构实例源码Demo
  3. java分割句子_关于Java的一些句子
  4. 今日头条竞价接口转发
  5. mySQL数据库中的备份代码_MySQL中的备份数据库
  6. leetcode 268
  7. java.lang.NoSuchFieldError: No instance field
  8. Python----面试题(二)
  9. STM32的2.02固件库提供的启动文件详解 stm32f10x_vector.s
  10. DOM事件流三个阶段
  11. 使用XAML和SharpMap渲染一幅地图
  12. python超时处理_Python如何实现让一个函数超时退出?
  13. Java 处理 XML 的三种主流技术及介绍
  14. 机器学习——数学建模应用
  15. 如何把图片裁剪为圆形
  16. updating mysql.pid_MySQL启动报错-The server quit without updating PID file[FAILED]mysql/mysql.pid)...
  17. 来信, 创业 和 移动互联网
  18. 蓝桥杯真题 18省4-测试次数 x星球的居民脾气不太好,但好在他们生气的时候唯一的异常举动是:摔手机。 各大厂商也就纷纷推出各种耐摔型手机。x星球的质监局规定了手机必须经过耐摔测试,并且评定出一个耐
  19. 大数据的应用场景都有哪些(交通篇)
  20. 7-20 打印九九口诀表 (15 分) 下面是一个完整的下三角九九口诀表:

热门文章

  1. neo4j jdbc中文乱码
  2. pip “Cannot uninstall ‘pip包‘. It is a distutils installed project...“ 解决方法
  3. [转载] Python杂记之 list.clear()方法,清空列表
  4. [转载] LeetCode题解(面试16.22):兰顿蚂蚁(Python)
  5. [转载] 50个数据可视化最有价值的图表(附完整Python代码,建议收藏)
  6. Navicat的使用,连表查询,python代码操作sql语句
  7. elementUI 日期选择控件少一天的问题解决方法
  8. git 常用命令及虚拟机服务器仓库搭建
  9. 跟我一起做面试题-linux线程编程(2)
  10. Balanced Numbers数位dp