小白第一次在windows安装,老大之前有发布过教程,小白不是很明白,在群主大人的指导下完成,把这个过程截图下来,希望有需要的童鞋少走一些弯路,下面教程系统是64位,32位安装方法一致,把软件换成32位即可,老司机勿喷!
环境安装包合集百度云网盘
http://pan.baidu.com/s/1bp6c35l 密码:5anx
第一步:安装JRE
下载地址: http://www.java.com/zh_CN/download/



环境变量----





第二步:安装tomcat
下载地址:http://www.51yd.org/apache-tomcat-7.0.52.exe






第三步:安装数据库Postgresql
下载地址:
32bit http://www.51yd.org/postgresql-9.3.3-1-windows.exe
64bit http://www.51yd.org/postgresql-9.3.3-1-windows-x64.exe






添加本地访问权限
D:\YiDuNovel\PostgreSQL\data\pg_hba.conf
修改如下内容
host all all 127.0.0.1/32 md5
↓
host all all 127.0.0.1/32 trust
重启下postgresql
第四部步:连接postgresql


第五部步:拷贝易读程序到ROOT
D:\YiDuNovel\Tomcat\webapps\ROOT



1.将tomcat/webapp下的内容备份或直接删除!
2.把程序解压缩到tomcat/webapp/ROOT下面
3.更改数据库链接的密码
文件位置:WEB-INF\classes\jdbc.properties
jdbc.password=postgres
把postgres改成你安装postgres时的密码
4.启动tomcat
5.输入www.xxx.com/install/index

到这里环境配置和易读程序就全部完工了,接下来配置易读采集器
第五步:采集规则
1.把准备好的采集规则拷贝到'rules'目录
2.编辑文件'collect.ini' rule_name=hk020.com.xml 把红色部分替换成你的采集规则名称
3.编辑文件'jdbc.properties' jdbc.password=postgres 把红色部分改成自己安装数据库输入的密码
4.编辑文件'run.ini' 这样演示是线程采集设置【群主教程】
这里教大家一个方法,对一个站开两个线程,一个线程采集全部小说,另一个线程采集更新小说。
添加下面两条,第一条默认是采集更新列表的,第二条是指定小说编号,现在的设置是从1到88888,可以根据自己的想法设置
一,-rule hk020.com.xml -ca
-rule hk020.com.xml -c 1-88888
二,修改start.bat
默认的java -jar spider.jar -ca & 改成 java -jar spider.jar -m &
启动采集器就可以啦,这样就可以最快的从一个网站把数据都抓过来啦!
等把对方站的数据采集的差不多了,就可以把-rule hk020.com.xml -c 1-88888 去掉啦,用更新列表就可以啦!
另外如果要采集多个站的话,就在run.ini再加几条规则就可以啦
5.编辑文件'site.ini' 把下面红色部分替换成你安装Tomcat的绝对路径,下面是演示
#本站根目录
base_path=D:/YiDuNovel/Tomcat/webapps/ROOT/
#章节txt存放绝对路径
txt_file=D:/YiDuNovel/Tomcat/webapps/ROOT/txt/#subDir#/#articleNo#/#chapterNo#.txt
#文章封面存放绝对路径
cover_dir=D:/YiDuNovel/Tomcat/webapps/ROOT/cover/#subDir#/#articleNo#/
全部编辑完之后我们现在可以启动采集器了,如果安装配置没什么问题现在是可以正常采集的
好废话不多说,我们双击'start.bat' 启动 'stop.bat' 停止
到此易读程序全部安装完成,可以放在一边不用管了
这里提供一个已经配置好的'yispider2.1' 替换上面教程即可!
链接:http://pan.baidu.com/s/1skAJzUt 密码:ydcl
第六步:解决搜索框编码问题(搜索不到内容)
打开tomcat的conf/server.xml,找到下面这行配置:
<Connector port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />
改为
<Connector executor="tomcatThreadPool"
port="80" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" URIEncoding="UTF-8"/>