摘要: LVS安装部署一、LVS安装(CENTOS)1、LVS模块ip_vs已经内置在LINUX内核中,一般情况下ip_vs并没有启动,可以通过lsmod|grepip_vs查看,能够看到信息表示模块已经加载,否则用modprobeip_vs来启动。2、192.168.0.156/200/201上都启动ip_vs模块。二、VIP服务器IPVSADM安装1、ipvsadm下载地址http://www.linuxvirtualserver.org/software/index.html2、源代码安装的话请根据内核版本(uname-a)来选择版本,注意对应版本对内核版本的要求。3、CentOS5.5上直接用 阅读全文
posted @ 2013-06-27 20:44 ybtyoyo 阅读(1431) 评论(0) 推荐(0) 编辑
摘要: Redis Sentinel - 监控软件说明文档http://redis.io/topics/sentinel使用说明:http://blog.163.com/a12333a_li/blog/static/87594285201304103257837/sentinel.conf{port 26379sentinel monitor mymaster 127.0.0.1 6379 1sentinel down-after-milliseconds mymaster 30000sentinel can-failover mymaster yessentinel parallel-syncs m 阅读全文
posted @ 2013-03-05 16:48 ybtyoyo 阅读(509) 评论(1) 推荐(0) 编辑
摘要: 一、下载luajit 2.0http://luajit.org/download.html二、下载nginx源代码http://www.nginx.org/en/download.html三、下载nginx_devel_kithttps://github.com/simpl/ngx_devel_kit/tags四、下载lua-nginx-modulehttps://github.com/chaoslawful/lua-nginx-module/tags五、先安装luajitmake & make install六、设置环境变量:export LUAJIT_LIB=/usr/local/ 阅读全文
posted @ 2012-11-26 19:18 ybtyoyo 阅读(788) 评论(0) 推荐(0) 编辑
摘要: 1、编译时带上--with-http_stub_status_module模块./configure--with-http_stub_status_module2、nginx.conf增加配置location /status { stub_status on; }3、在浏览器上输入http://ip/status查看nginx的状态Active connections: 1 server accepts handled requests 57 57 57 Reading: 0 Writing: 1 Waiting: 0 阅读全文
posted @ 2012-11-02 14:56 ybtyoyo 阅读(879) 评论(0) 推荐(0) 编辑
摘要: cut_nginx_log.sh:logs_path="/usr/local/nginx/logs/"mv ${logs_path}access.log ${logs_path}access_$(date -d "yesterday" +%Y%m%d).logkill -USR1 `cat /usr/local/nginx/logs/nginx.pid`然后将cut_nginx_log.sh加入到crontab中,定时在每天0点执行。 阅读全文
posted @ 2012-10-19 17:49 ybtyoyo 阅读(193) 评论(0) 推荐(0) 编辑
摘要: post请求:http://127.0.0.1/do?action=1&account=test11111用curl来请求如下:curl -d action=1 -d account=test11111 http://127.0.0.1/do 阅读全文
posted @ 2012-10-19 11:32 ybtyoyo 阅读(1469) 评论(0) 推荐(0) 编辑
摘要: 直接设置:mysql> set lower_case_table_names=1;ERROR 1238 (HY000): Variable 'lower_case_table_names' is a read only variable在/etc/my.cnf的[mysqld]下增加lower_case_table_names = 1 阅读全文
posted @ 2012-06-27 20:26 ybtyoyo 阅读(253) 评论(0) 推荐(0) 编辑
摘要: uuid.lib(unknwn_i.obj) : fatal error LNK1103 或uuid.lib(oaidl_i.obj) : fatal error LNK1103引起uuid.lib(oaidl_i.obj) : fatal error LNK1103: debugging information corrupt; recompile module 连接错误的原因是使用了新版本的windows SDK v7.1,用Microsoft Visual Studio 8\VC\lib自带的uuid.lib覆盖新版uuil.lib即可,覆盖之前注意保存副本!遇到此类问题还有:|shel 阅读全文
posted @ 2012-04-17 09:58 ybtyoyo 阅读(770) 评论(0) 推荐(0) 编辑
摘要: 转自:http://ticktick.blog.51cto.com/823160/431329最近在Linux下编程发现一个诡异的现象,就是在链接一个静态库的时候总是报错,类似下面这样的错误:(.text+0x13): undefined reference to `func' 关于undefined reference这样的问题,大家其实经常会遇到,在此,我以详细地示例给出常见错误的各种原因以及解决方法,希望对初学者有所帮助。1. 链接时缺失了相关目标文件(.o) 测试代码如下: 然后编译。gcc -c test.c gcc –c main.c 得到两个 .o 文件,一个是 main 阅读全文
posted @ 2012-04-09 13:19 ybtyoyo 阅读(1847) 评论(0) 推荐(0) 编辑
摘要: Linux下redis的安装及运行可以参考随笔(redis入门与安装)一、jedis下载在https://github.com/xetorthio/jedis/downloads上下载jedis-2.0.0.jar二、将jedis-2.0.0.jar放入eclipse\plugins的目录中打开Window->Preferences->Java->Install JREs在jre6->Edit->Add External JARs把eclipse\plugins\jedis-2.0.0.jar添加进来。三、进入Maven生成Helloworld编辑pom.xml& 阅读全文
posted @ 2011-12-27 16:51 ybtyoyo 阅读(4198) 评论(0) 推荐(0) 编辑