Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

searcher 搜索不到东西 #21

Open
chy373 opened this issue Mar 17, 2017 · 6 comments
Open

searcher 搜索不到东西 #21

chy373 opened this issue Mar 17, 2017 · 6 comments

Comments

@chy373
Copy link

chy373 commented Mar 17, 2017

searcher 日志:
2017/03/17 20:56:57 request filter =
2017/03/17 20:56:57 http://127.0.0.1:39610/service/meta/test/index/get
2017/03/17 20:56:57 http://127.0.0.1:39610/service/meta/test/index/get
2017/03/17 20:56:57 text17031603983756

2017/03/17 20:56:57 map[text17031603983756: :]
2017/03/17 20:56:57 FetchIndex symc key map[text17031603983756: :]
2017/03/17 20:56:57 stored get key text17031603983756
2017/03/17 20:56:57 stored get key result=
2017/03/17 20:56:57 fetchIndexMeta ok, token=3607866730897298,filePath=/home/poseidon/src/test/index/2017-03-16/textindex/part-00792.gz,offset=0,length=0
2017/03/17 20:56:57 FetchIndex routine field=text token=3607866730897298 path=/home/poseidon/src/test/index/2017-03-16/textindex/part-00792.gz
2017/03/17 20:56:57 ReadZip url=http://127.0.0.1:39997/read-hdfs?path=/home/poseidon/src/test/index/2017-03-16/textindex/part-00792.gz&offset=0&length=0
2017/03/17 20:56:57 unzip err : len=0
2017/03/17 20:56:57 ReadHDFS indexData read err EOF token=3607866730897298
2017/03/17 20:56:57 FetchIndex routine field=text token=3607866730897298 docList.size=0
2017/03/17 20:56:57 SearchDocItems token 3607866730897298 FetchIndex err=read hdfs fail
2017/03/17 20:56:57 ---- 127.0.0.1:36418 handleSearch &{100 0 0 {2017-03-16 test map[text:3607866730897298]}}, err=read hdfs fail

不管搜什么 len都是0 导致读hdfs失败

不知道哪有问题

@guojun1992
Copy link
Contributor

ReadZip url=http://127.0.0.1:39997/read-hdfs?path=/home/poseidon/src/test/index/2017-03-16/textindex/part-00792.gz&offset=0&length=0

看读的这个url是不对的,offset和length是从memcache解析protocbuffer出来的字段,现在是默认值,应该是入memcache出错,或者这个分词在memcache没找到,贴一下入memcache的日志

@chy373
Copy link
Author

chy373 commented Mar 17, 2017

@guojun1992 嗯 我吧meta里的配置项改成redis了,因为用memcached的话searcher是报另外一个错:
2017/03/17 20:26:00 request filter =
2017/03/17 20:26:00 http://127.0.0.1:39610/service/meta/test/index/get
2017/03/17 20:26:00 http://127.0.0.1:39610/service/meta/test/index/get
2017/03/17 20:26:00
2017/03/17 20:26:00 map[]
2017/03/17 20:26:00 FetchIndex symc key map[]
2017/03/17 20:26:00 stored get key text17031600097610
2017/03/17 20:26:00 fetchIndexMeta token=2,storedGetError=dockey is not found
2017/03/17 20:26:00 FetchIndex routine field=text token=2 nil_data
2017/03/17 20:26:00 FetchIndex routine field=text token=2 docList.size=0
2017/03/17 20:26:00 SearchDocItems token 2 FetchIndex err=dockey is not found
2017/03/17 20:26:00 ---- 127.0.0.1:34573 handleSearch &{100 0 0 {2017-03-16 test map[text:2]}}, err=dockey is not found

我的redis配置是改成这样的:

test 业务的 Doc Meta 信息存储的NoSQL配置信息

[/service/meta/backend-store/doc/test]
timeout_ms = 3000
address = 127.0.0.1:6789
store_type = redis
password = 6288cfbe

test 业务的 Index Meta 信息存储的NoSQL配置信息

[/service/meta/backend-store/index/test]
timeout_ms = 3000
address = 127.0.0.1:6789
store_type = redis
password = 6288cfbefe

这样有问题么

我在index下执行sh bin/start.sh 2017-03-16生成index是没有报错的,hadoop任务全都执行成功了。我查看了下redis里好像没有多出来key,如果index生成成功的话,redis里会多出来键吧

@guojun1992
Copy link
Contributor

@chy373 是你入meta信息出错了

2017/03/17 20:26:00 stored get key text17031600097610
2017/03/17 20:26:00 fetchIndexMeta token=2,storedGetError=dockey is not found

从kvdb(memcache或者redis)没有找到text17031600097610这个key
1、确认redis是否能正常工作
2、贴一下meta的错误日志

@chy373
Copy link
Author

chy373 commented Mar 18, 2017

@guojun1992

  1. redis应该是正常工作的,因为idgenerator是正常工作的,redis里现在有一个test_20170316的key,应该是idgenerator生成的
  2. 很奇怪 meta下面是没有日志的,我如何确定meta是正常工作的,如果meta不是正常工作,生成index的hadoop任务不会报错么

@guojun1992
Copy link
Contributor

从你的描述看来,应该是build索引出错了,你确定build索引最后结果显示的是sucess吗?这里交流效率太低,加一下QQ群我们聊一下

@zhouyuan-dev
Copy link

怎么解决的,这个能贴下嘛,我现在也是这个问题了。查不到数据,meta数据放到redis里面的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants