上一页 1 ··· 25 26 27 28 29 30 31 32 33 ··· 43 下一页

2012年8月23日

mysql UDF接口 网络编程(代码改进版-非阻塞,超时重传)

摘要: #ifdef STANDARD/* STANDARD is defined, don't use any mysql functions */#include <stdlib.h>#include <stdio.h>#include <string.h>#ifdef __WIN__typedef unsigned __int64 ulonglong; /* Microsofts 64 bit types */typedef __int64 longlong;#elsetypedef unsigned long long ulonglong;typed 阅读全文

posted @ 2012-08-23 16:13 cn三少<script></script> 阅读(312) 评论(0) 推荐(0) 编辑

HTTP_POST———使用mysql_udf与curl库完成http_post通信模块(mysql_udf,multi_curl,http,post)

摘要: HTTP_POST———使用mysql_udf与curl库完成http_post通信模块(mysql_udf,multi_curl,http,post)这个模块其目前主要用于xoyo江湖的sns与kingsoft_xoyo自主研发的TCSQL数据库做数据同步,当有feed插入sns数据库,使用触 发器调用该模块,向tcsql数据库发送同步数据。也可以使用该模块与其它使用socket接口的数据库或程序做转发与同步。 http_post模块主要使用mysql_udf接口,与curl库两部分技术。 mysql_udf是mysql为c语言提供的一个接口,通过这个接口,用户可以自定义mysql的函数,通 阅读全文

posted @ 2012-08-23 15:49 cn三少<script></script> 阅读(814) 评论(0) 推荐(0) 编辑

2012年8月21日

文件备份,同步工具rsync服务器端的安装及配置

摘要: 文件备份,同步工具rsync服务器端的安装及配置张映 发表于 2010-02-25分类目录: 服务器相关一,什么是rsyncrsync是类unix系统下的数据镜像备份工具,从软件的命名上就可以看出来了——remote sync。它的特性如下:可以镜像保存整个目录树和文件系统。可以很容易做到保持原来文件的权限、时间、软硬链接等等。无须特殊权限即可安装。优化的流程,文件传输效率高。可以使用rcp、ssh等方式来传输文件,当然也可以通过直接的socket连接。支持匿名传输,以方便进行网站镜象。二,我用rsync干什么我画图很烂,不好意思。上面这个图,应当意思表达很明确了。简单说一下就是,web se 阅读全文

posted @ 2012-08-21 16:32 cn三少<script></script> 阅读(329) 评论(0) 推荐(0) 编辑

mysql 复制表数据,表结构的3种方法

摘要: 什么时候我们会用到复制表?例如:我现在对一张表进行操作,但是怕误删数据,所以在同一个数据库中建一个表结构一样,表数据也一样的表,以作备份。如果用mysqldump比较麻烦,备份.MYD,.MYI这样的文件呢,操作起来也还是麻烦。一,复制表结构方法1:查看复制打印?mysql>createtablealikeusers;//复制表结构QueryOK,0rowsaffected(0.50sec)mysql>showtables;+----------------+|Tables_in_test|+----------------+|a||users|+----------------+ 阅读全文

posted @ 2012-08-21 15:23 cn三少<script></script> 阅读(222) 评论(0) 推荐(0) 编辑

实例说明optimize table在优化mysql时很重要

摘要: 今天在看CU的时候,发现有人问有关optimize来表优化的问题,当年因为这个问题,困扰我很长一段时间,今天有空我把这个问题,用实际数据来展示出来,让大家可以亲眼来看看,optimize table的重要作用,而不是似是而非的估计了。一,原始数据1,数据量查看复制打印?mysql>selectcount(*)astotalfromad_visit_history;+---------+|total|+---------+|1187096|//总共有118万多条数据+---------+1rowinset(0.04sec)2,存放在硬盘中的表文件大小查看复制打印?[root@BlackGh 阅读全文

posted @ 2012-08-21 15:10 cn三少<script></script> 阅读(171) 评论(0) 推荐(0) 编辑

2012年8月17日

CentOS桌面安装

摘要: 1.显示系统已经安装的组件,和可以安装的组件:#yum grouplist2.如果系统安装之初采用最小化安装,没有安装xwindow,那么先安装:#yum groupinstall "X Window System"3.安装GNOME桌面环境yum groupinstall "GNOME Desktop Environment"4.安装KDE桌面环境yum groupinstall "KDE (K Desktop Environment)"5.卸载GNOME桌面环境yum groupremove "GNOME Desktop 阅读全文

posted @ 2012-08-17 13:55 cn三少<script></script> 阅读(182) 评论(0) 推荐(0) 编辑

2012年8月13日

log4cxx does not compile on kernel 2.6.29.6

摘要: socketoutputstream.cpp: In member function 'virtual void log4cxx::helpers::SocketOutputStream::write(log4cxx::helpers::ByteBuffer&, log4cxx::helpers::Pool&)':socketoutputstream.cpp:52: error: 'memcpy' was not declared in this scopeSame solution as before. I added '#includ 阅读全文

posted @ 2012-08-13 22:23 cn三少<script></script> 阅读(190) 评论(0) 推荐(0) 编辑

编译 apache-log4cxx-0.10.0inputstreamreader.cpp:66: error: ‘memmove’ was not declared in this sco

摘要: 添加补丁,patch -p1 <补丁名,下面为补丁的代码:diff -upr orig/apache-log4cxx-0.10.0//src/examples/cpp/console.cpp apache-log4cxx-0.10.0/src/examples/cpp/console.cpp--- orig/apache-log4cxx-0.10.0//src/examples/cpp/console.cpp 2008-04-01 00:34:52.000000000 +0200+++ apache-log4cxx-0.10.0/src/examples/cpp/console.cpp 阅读全文

posted @ 2012-08-13 21:29 cn三少<script></script> 阅读(1389) 评论(0) 推荐(0) 编辑

2012年8月12日

/usr/bin/ld: cannot find -lmysqlclient

摘要: 在make osdb工具时出现错误g++ -g -O2 -L/usr/lib/mysql -lmysqlclient -o osdb OSDB.o Benchmark.o BenchmarkSuite.o BenchmarkTest.o Configuration.o Database.o DataPopulator.o Logger.o SingleUserMode.o Timer.o tinystr.o tinyxml.o tinyxmlerror.o tinyxmlparser.o dbms/MySQLDB.o /usr/bin/ld: cannot find -lmysqlclient 阅读全文

posted @ 2012-08-12 11:55 cn三少<script></script> 阅读(442) 评论(0) 推荐(0) 编辑

解决/usr/bin/ld: cannot find -lmysqlclient错误

摘要: 类似/usr/bin/ld: cannot find -xxxx的错误有很多, 首先我们可以最简单的判断一下:这类情况一般是由于缺乏某某库文件, 又或者可能是由于已存在的库问题版本不对造成的一般都是解决的办法就是安装缺乏的devel包就可以解决, 当然还有其他的未知因素, 我们看一个实例:我在一台装centos5.2 x86_64的系统上配置php环境, 提示这个错误"/usr/bin/ld: cannot find -lmysqlclient"于是我安装了# yum -y install mysql-devel结果提示依旧, 我根据提示查看config.log/usr/b 阅读全文

posted @ 2012-08-12 11:54 cn三少<script></script> 阅读(1888) 评论(0) 推荐(0) 编辑

上一页 1 ··· 25 26 27 28 29 30 31 32 33 ··· 43 下一页

导航