HandlerSocket安装

安装Mysql
PREFIX=/opt/app
tar zxvf mysql-5.1.51.tar.gz
cd mysql-5.1.51
./configure  –prefix=$PREFIX/mysql-5.1.51 –enable-assembler –with-client-ldflags=-all-static –with-unix-socket-path=/tmp/mysql.sock –with-charset=utf8  –enable-thread-safe-client –with-pthread  –without-debug –with-big-tables  –enable-community-features –enable-profiling  –enable-local-infile  –with-fast-mutexes  –with-plugins=innobase,innodb_plugin && \
make -j 5 && \
strip sql/mysqld && \
make install && \
cd $PREFIX/mysql-5.1.51 && \
bin/mysql_install_db –user=mysql && \
cd ..

安装HandlerSocket
tar zxvfp ahiguti-HandlerSocket-Plugin-for-MySQL-a25ce9a.tar.gz && \
cd ahiguti-HandlerSocket-Plugin-for-MySQL-a25ce9a && \
./autogen.sh
./configure –prefix=$PREFIX/HandlerSocket-Plugin –with-mysql-source=/home/kingnet/mysql/mysql-5.1.51 –with-mysql-bindir=$PREFIX/mysql-5.1.51/bin  –with-mysql-plugindir=$PREFIX/mysql-5.1.51/lib/mysql/plugin && \
make && make install

修改my.conf配置

[mysqld]

loose_handlersocket_port = 9998

# the port number to bind to (for read requests)

loose_handlersocket_port_wr = 9999

# the port number to bind to (for write requests)

loose_handlersocket_threads = 16

# the number of worker threads (for read requests)

loose_handlersocket_threads_wr = 1

# the number of worker threads (for write requests)

open_files_limit = 65535

# to allow handlersocket accept many concurrent

# connections, make open_files_limit as large as

# possible.


在mysql里加载HandlerSocket插件
mysql> INSTALL PLUGIN handlersocket SONAME ‘handlersocket.so’;
mysql>SHOW PLUGINS; # 查看插件是否加载成

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/7682812/viewspace-683085/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/7682812/viewspace-683085/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值