-
Notifications
You must be signed in to change notification settings - Fork 0
/
csft.conf
94 lines (87 loc) · 3.24 KB
/
csft.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
source spdb1
{
type = mysql
sql_host = 192.168.25.1
sql_user = test
sql_pass = mima
sql_db = test
sql_port = 3306
sql_query_pre = SET NAMES utf8
sql_query = SELECT `id`, 1 AS table_id, `username`, `email`, `password` FROM spdb1
sql_attr_uint = table_id #从SQL读取到的值必须为整数
#sql_attr_timestamp = date_added #从SQL读取到的值必须为整数,作为时间属性
sql_query_info_pre = SET NAMES utf8 #命令行查询时,设置正确的字符集
sql_query_info = SELECT * WHERE ID=$id #命令行查询时,从数据库读取原始数据信息
}
source spdb2 : spdb1
{
sql_query = SELECT `id`, 2 AS table_id, `username`, `email`, `password` FROM spdb2
}
source spdb3 : spdb1
{
sql_query = SELECT `id`, 3 AS table_id, `username`, `email`, `password` FROM spdb3
}
source spdb4 : spdb1
{
sql_query = SELECT `id`, 4 AS table_id, `username`, `email`, `password` FROM spdb4
}
source spdb5 : spdb1
{
sql_query = SELECT `id`, 5 AS table_id, `username`, `email`, `password` FROM spdb5
}
#index定义
index spdb1
{
source = spdb1 #对应的source名称
path = /usr/local/coreseek/var/data/spdb1 #请修改为实际使用的绝对路径,例如:/usr/local/coreseek/var/...
docinfo = extern
mlock = 0
morphology = none
min_word_len = 1
ondisk_dict = 1
html_strip = 0
#中文分词配置,详情请查看:http://www.coreseek.cn/products-install/coreseek_mmseg/
#charset_dictpath = /usr/local/mmseg3/etc/ #BSD、Linux环境下设置,/符号结尾
charset_dictpath = /usr/local/mmseg3/etc/ #Windows环境下设置,/符号结尾,最好给出绝对路径,例如:C:/usr/local/coreseek/etc/...
charset_type = zh_cn.utf-8
}
index spdb2 : spdb1
{
source = spdb2
path = /usr/local/coreseek/var/data/spdb2
}
index spdb3 : spdb1
{
source = spdb3
path = /usr/local/coreseek/var/data/spdb3
}
index spdb4 : spdb1
{
source = spdb4
path = /usr/local/coreseek/var/data/spdb4
}
index spdb5 : spdb1
{
source = spdb5
path = /usr/local/coreseek/var/data/spdb5
}
#全局index定义
indexer
{
mem_limit = 200M #默认32M,不要太大,否则会报错
}
#searchd服务定义
searchd
{
listen = 9312 #查询服务监听端口,开启了才会工作
read_timeout = 5 #超时
max_children = 30 #最大进程
max_matches = 1000 #返回1000条
seamless_rotate = 0
preopen_indexes = 0
unlink_old = 1
pid_file = /usr/local/coreseek/var/log/searchd.pid #请修改为实际使用的绝对路径,例如:/usr/local/coreseek/var/...
log = /usr/local/coreseek/var/log/searchd.log #请修改为实际使用的绝对路径,例如:/usr/local/coreseek/var/...
query_log = /usr/local/coreseek/var/log/query.log #请修改为实际使用的绝对路径,例如:/usr/local/coreseek/var/...
binlog_path = #关闭binlog日志
}