免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
楼主: redor
打印 上一主题 下一主题

[C] 发布一个单机版的spider,分布式版本还在开发中 [复制链接]

论坛徽章:
0
31 [报告]
发表于 2008-06-13 20:29 |只看该作者
数字指纹不是hash,就是一串很长很长的二进制,比如0001001000101110...1100
系统运行的时候先把这串0101加载到内存,然后url判重的时候计算url对应011011中1的index,比如计算出来的是 7,12,67,88,102, 就察看00100101中的第7,12,67,88,102是否都是1,是的话就重复了,不是的话就不重,同时把不是1的位置为1待下次判重使用

论坛徽章:
0
32 [报告]
发表于 2008-06-14 03:40 |只看该作者
[root@localhost tmp]# cd tlink
[root@localhost tlink]# ls -al
总计 400
drwxr-xr-x 3  501 games   4096 06-11 18:04 .
drwxrwxrwt 6 root root    4096 06-14 03:37 ..
-rw-r--r-- 1  501 games    563 06-11 18:04 basedef.h
-rw-r--r-- 1  501 games   4077 06-11 18:03 hio.h
-rw-r--r-- 1  501 games   2890 06-11 18:03 http.c
-rw-r--r-- 1  501 games  14263 06-11 18:03 http.h
-rw-r--r-- 1  501 games  56709 06-11 18:03 link.c
-rw-r--r-- 1  501 games   3793 06-11 18:03 link.h
-rw-r--r-- 1  501 games   4863 06-11 18:03 logger.h
-rw-r--r-- 1  501 games   3519 06-11 18:03 md5.c
-rw-r--r-- 1  501 games   7382 06-11 18:03 md5.h
-rw-r--r-- 1  501 games   1398 06-11 18:03 mutex.h
-rwxr-xr-x 1  501 games    135 06-11 18:04 s.sh
drwxr-xr-x 6  501 games   4096 06-11 18:03 .svn
-rw-r--r-- 1  501 games   5760 06-11 18:03 timer.h
-rwxr-xr-x 1  501 games 130344 06-11 18:04 tlink
-rw-r--r-- 1  501 games  11257 06-11 18:03 trie.c
-rw-r--r-- 1  501 games  28254 06-11 18:03 trie.h
-rw-r--r-- 1  501 games   2246 06-11 18:03 zstream.c
-rw-r--r-- 1  501 games    312 06-11 18:03 zstream.h


编译不通过
[root@localhost tlink]# ./s.sh
在包含自 http.c:1 的文件中:
http.h:6:19: 错误:sbase.h:没有那个文件或目录
在包含自 link.c:19 的文件中:
http.h:6:19: 错误:sbase.h:没有那个文件或目录
link.c:857:20: 错误:evbase.h:没有那个文件或目录
link.c:885: 错误:expected specifier-qualifier-list before ‘EVENT’
link.c:890: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
link.c: 在函数 ‘ev_handler’ 中:
link.c:1121: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1121: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1121: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1121: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1121: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1125: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1126: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1126: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1127: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1135: 错误:‘E_READ’ 未声明 (在此函数内第一次使用)
link.c:1135: 错误:(即使在一个函数内多次出现,每个未声明的标识符在其
link.c:1135: 错误:所在的函数内只报告一次。)
link.c:1137: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1137: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1137: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1137: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1137: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1140: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1141: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1141: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1141: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1141: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1141: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1146: 错误:‘E_WRITE’ 未声明 (在此函数内第一次使用)
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1148: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1152: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1152: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1152: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1154: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c: 在函数 ‘pthread_handler’ 中:
link.c:1169: 错误:‘evbase’ 未声明 (在此函数内第一次使用)
link.c:1171: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1174: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘resp’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1182: 错误:‘E_READ’ 未声明 (在此函数内第一次使用)
link.c:1182: 错误:‘E_WRITE’ 未声明 (在此函数内第一次使用)
link.c:1182: 错误:‘E_PERSIST’ 未声明 (在此函数内第一次使用)
link.c:1182: 错误:‘DCON’ 没有名为 ‘event’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员
link.c:1182: 错误:‘DCON’ 没有名为 ‘req’ 的成员


libevbase-0.0.14库并没sbase.h 文件
[root@localhost src]# ls
evbase.c      evdevpoll.o  evpoll.h    evrtsig.o    evwin32.lo    Makefile.in
evbase.h      evepoll.c    evpoll.lo   evselect.c   evwin32.o     mutex.c
evbase.lo     evepoll.h    evpoll.o    evselect.h   libevbase.la  mutex.h
evbase.o      evepoll.lo   evport.c    evselect.lo  logger.c      mutex.lo
ev_cli        evepoll.o    evport.h    evselect.o   logger.h      mutex.o
ev_cli.c      evkqueue.c   evport.lo   ev_serv      logger.lo
ev_cli.o      evkqueue.h   evport.o    ev_serv.c    logger.o
evdevpoll.c   evkqueue.lo  evrtsig.c   ev_serv.o    log.h
evdevpoll.h   evkqueue.o   evrtsig.h   evwin32.c    Makefile
evdevpoll.lo  evpoll.c     evrtsig.lo  evwin32.h    Makefile.am
[root@localhost src]# pwd
/tmp/libevbase-0.0.14/src


系统
[root@localhost ~]# uname -a
Linux localhost.localdomain 2.6.18-53.1.21.el5 #1 SMP Tue May 20 09:34:18 EDT 2008 i686 i686 i386 GNU/Linux

GCC
[root@localhost ~]# gcc -v
使用内建 specsã

论坛徽章:
0
33 [报告]
发表于 2008-06-14 12:22 |只看该作者

回复 #33 sunki 的帖子

把头文件里的sbase去掉,可能是没有去掉

论坛徽章:
0
34 [报告]
发表于 2008-06-15 00:47 |只看该作者
:wink: 准备向搜索发展!!!

论坛徽章:
0
35 [报告]
发表于 2008-06-15 15:14 |只看该作者
性能和分布式问题考虑的怎么样了?到国内权威的系统优化站点去看看,那里有很多这方面的资料。
http://www.distributed-cluster.com/

论坛徽章:
0
36 [报告]
发表于 2008-06-15 19:43 |只看该作者
好东西,正好想研究一下!  
robble 该用户已被删除
37 [报告]
发表于 2008-06-15 21:59 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
robble 该用户已被删除
38 [报告]
发表于 2008-06-15 22:00 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
robble 该用户已被删除
39 [报告]
发表于 2008-06-15 22:04 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
robble 该用户已被删除
40 [报告]
发表于 2008-06-15 22:04 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP