gearmand的安装
2016-03-12 10:53
330 查看
1、安装gperf libuuid-devel
yum install -y gperf libuuid-devel
2、安装 libevent
yum install libevent libevent-devel
如果libevent版本低,则手动安装
wget https://sourceforge.net/projects/levent/files/libevent/libevent-2.0/libevent-2.0.22-stable.tar.gz tar -zxvf libevent-2.0.22-stable.tar.gz
cd libevent-2.0.22-stable
./configure
make
make install
3、添加环境变量
echo export LD_LIBRARY_PATH=/usr/local/lib >> ~/.bash_profile
shutdown -r now
4、安装gearmand服务
wget https://launchpad.net/gearmand/1.2/1.1.12/+download/gearmand-1.1.12.tar.gz tar -zxvf gearmand-1.1.12.tar.gz
cd gearmand-1.1.12
./configure --prefix=/usr/local/gearmand (如果libevent安装时指定的目录,则带上参数 --with-libevent-prefix=/usr/lib64)
make
make install
5、安装成功图
# /usr/local/gearmand/bin/gearman
6、创建日志/home/data/gearmand/gearmand.log
# touch /home/data/gearmand/gearmand.log
7、启动
# /usr/local/gearmand/sbin/gearmand -d -u root -L 192.168.161.136 --log-file=/home/data/gearmand/gearmand.log
查是否运行
# ps axu | grep gearmand
查看监听端口
# netstat -anp | grep 4730 centos6
# ss -anp | grep 4730 centos7
8、安装php扩展
wget http://pecl.php.net/get/gearman-1.1.2.tgz tar -zxvf gearman-1.1.2.tgz
cd gearman-1.1.2
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-gearman=/usr/local/gearmand
make
make install
安装成功后会显示gearman.so的路径,在php.ini文件中加入扩展
yum install -y gperf libuuid-devel
2、安装 libevent
yum install libevent libevent-devel
如果libevent版本低,则手动安装
wget https://sourceforge.net/projects/levent/files/libevent/libevent-2.0/libevent-2.0.22-stable.tar.gz tar -zxvf libevent-2.0.22-stable.tar.gz
cd libevent-2.0.22-stable
./configure
make
make install
3、添加环境变量
echo export LD_LIBRARY_PATH=/usr/local/lib >> ~/.bash_profile
shutdown -r now
4、安装gearmand服务
wget https://launchpad.net/gearmand/1.2/1.1.12/+download/gearmand-1.1.12.tar.gz tar -zxvf gearmand-1.1.12.tar.gz
cd gearmand-1.1.12
./configure --prefix=/usr/local/gearmand (如果libevent安装时指定的目录,则带上参数 --with-libevent-prefix=/usr/lib64)
make
make install
5、安装成功图
# /usr/local/gearmand/bin/gearman
6、创建日志/home/data/gearmand/gearmand.log
# touch /home/data/gearmand/gearmand.log
7、启动
# /usr/local/gearmand/sbin/gearmand -d -u root -L 192.168.161.136 --log-file=/home/data/gearmand/gearmand.log
查是否运行
# ps axu | grep gearmand
查看监听端口
# netstat -anp | grep 4730 centos6
# ss -anp | grep 4730 centos7
8、安装php扩展
wget http://pecl.php.net/get/gearman-1.1.2.tgz tar -zxvf gearman-1.1.2.tgz
cd gearman-1.1.2
/usr/local/php/bin/phpize
./configure --with-php-config=/usr/local/php/bin/php-config --with-gearman=/usr/local/gearmand
make
make install
安装成功后会显示gearman.so的路径,在php.ini文件中加入扩展
相关文章推荐
- 第二周的学习进度情况
- 使用bochs运行Linux Kernel-2.4.0
- 使用bochs运行Linux Kernel-2.4.0
- 【J2EE】:MVC模式的简介与分析
- 欢迎使用CSDN-markdown编辑器
- 构建之法阅读笔记(02)
- QML中的ExclusiveGroup
- Java AbstractList 源代码分析
- Git学习(五)
- 帧内预测模式RDO
- 抽象类与接口
- C语言—指针数组
- 四则运算2
- Ruby SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B:
- Qt 连接Mysql win10
- QML中的TextEdit和TextArea的区别
- unity提示消息窗口
- 嵌入式linux:嵌入式Linux中让应用程序自动启动
- xml中的特殊符号
- Android jni学习