-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathsphinx.conf.example
55 lines (49 loc) · 2.84 KB
/
sphinx.conf.example
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
source magento_fulltext {
type = mysql
# Host details - ensure you update this to match your settings
sql_host = localhost
sql_user =
sql_pass =
sql_db =
sql_port = 3306
sql_sock = /var/run/mysqld/mysqld.sock # Either leave this out for TCP (slightly slower) or update to your sock path!
# Core settings - this is tuned to extension table layout
sql_query_pre = SET NAMES utf8 # We're using UTF-8 encoding so run this before
sql_query = SELECT product_id, name, name_attributes, category, data_index FROM sphinx_catalogsearch_fulltext
sql_query_info = SELECT product_id, name, name_attributes, category, data_index FROM sphinx_catalogsearch_fulltext WHERE product_id=$id
}
index fulltext {
source = magento_fulltext
path = /var/lib/sphinxsearch/data/magento.sphinx.index # Feel free to change
#morphology = libstemmer_german, metaphone
morphology = stem_en
#wordforms = /etc/sphinxsearch/stemmingoverride.txt
min_word_len = 1 # Indexes all words
charset_type = utf-8
# added charset_table to process umlauts etc. correctly
# source: http://sphinxsearch.com/forum/view.html?id=19
charset_table = 0..9, A..Z->a..z, _, a..z, U+410..U+42F->U+430..U+44F, U+430..U+44F,U+C5->U+E5, \
U+E5, U+C4->U+E4, U+E4, U+D6->U+F6, U+F6, U+16B, U+0c1->a, U+0c4->a, U+0c9->e, U+0cd->i, \
U+0d3->o, U+0d4->o, U+0da->u, U+0dd->y, U+0e1->a, U+0e4->a, U+0e9->e, U+0ed->i, U+0f3->o, \
U+0f4->o, U+0fa->u, U+0fd->y, U+104->U+105, U+105, U+106->U+107, U+10c->c, U+11d->c, \
U+10e->d, U+10f->d, U+116->U+117, U+117, U+118->U+119, U+11a->e, U+11b->e, U+12E->U+12F, \
U+12F, U+139->l, U+13a->l, U+13d->l, U+13e->l, U+141->U+142, U+142, U+143->U+144, \
U+144,U+147->n, U+148->n, U+154->r, U+155->r, U+158->r, U+159->r, U+15A->U+15B, U+15B, \
U+160->s, U+160->U+161, U+161->s, U+164->t, U+165->t, U+16A->U+16B, U+16B, U+16e->u, \
U+16f->u, U+172->U+173, U+173, U+179->U+17A, U+17A, U+17B->U+17C, U+17C, U+17d->z, \
U+17e->z, U+DC->U+FC, U+DF, U+FC
blend_chars = - # This presumes people won't type a hyphen into the search bar: quite likely
blend_mode = trim_both #
html_strip = 1 # Just in case anyone tries to get clever in the admin panel and use HTML
}
indexer {
mem_limit = 256M # Change this to something that suits your server
}
searchd {
pid_file = /var/run/sphinxsearch/searchd.pid
compat_sphinxql_magics = 0
log = /var/log/sphinxsearch/searchd.log
read_timeout = 5
client_timeout = 10 # Make sure you get rid of the 5 minute timeout!
preopen_indexes = 1
}