最新消息:

ubuntu 10.04下安装配置gearmand+mysql持久化队列

Ubuntu admin 3610浏览 0评论

Author:gaojinbo
Time:2012-01-01
Email:admin@gaojinbo.com

ubuntu 10.04下安装配置gearman安装配置,gearman mysql持久化队列配置

官方网站
http://gearman.org/

 

一、安装配置
1.下载地址
wget http://launchpad.net/gearmand/trunk/0.25/+download/gearmand-0.25.tar.gz

 

2.安装依赖包
apt-get install uuid-dev libevent-dev libboost-all-dev libdrizzle-dev

 

3.编译安装gearmand

tar xvzf gearmand-0.25.tar.gz
cd gearmand-0.25
libdrizzle_CFLAGS="-I /usr/local/include/libdrizzle/" 
libdrizzle_LIBS="-L/usr/local/lib -ldrizzle"  ./configure
make
make install

 

4.建立数据库及表,用户密码

CREATE TABLE IF NOT EXISTS `gearman_queue` (

  `unique_key` varchar(64) NOT NULL,

  `function_name` varchar(255) NOT NULL,

  `priority` int(11) NOT NULL,

  `data` longblob NOT NULL,

`when_to_run` INT, PRIMARY KEY  (`unique_key`)

) ENGINE=MyISAM DEFAULT CHARSET=utf8;

 

5.#start gearmand job server

/usr/local/sbin/gearmand -d -u nobody -q libdrizzle 
--libdrizzle-host=127.0.0.1 --libdrizzle-user=root  
--libdrizzle-password=gaojinbo.com --libdrizzle-db=gearman 
--libdrizzle-table=gearman_queue --libdrizzle-mysql 
--libdrizzle-port=3306 -vvv

 

配置完成!

转载请注明:爱开源 » ubuntu 10.04下安装配置gearmand+mysql持久化队列

您必须 登录 才能发表评论!