Indexer Warnings/Error
Hello,
Piler version = piler-1.1.0 Sphinx = sphinxsearch_2.2.6-release-0ubuntu12~trusty_amd64.deb
During a fresh install I run a indexer --all and it fails on the tag1 and note1 indexes with id is not a valid attribute name. Detailed output below.
su - piler
$ indexer --config /etc/sphinxsearch/sphinx.conf --all
Sphinx 2.2.6-id64-release (r4843)
Copyright (c) 2001-2014, Andrew Aksyonoff
Copyright (c) 2008-2014, Sphinx Technologies Inc (http://sphinxsearch.com)
using config file '/etc/sphinxsearch/sphinx.conf'...
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'enable_star' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: key 'charset_type' was permanently removed from Sphinx configuration. Refer to documentation for details.
WARNING: 12 more warnings skipped.
indexing index 'main1'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.007 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'main2'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.004 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'main3'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.004 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'main4'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.003 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'dailydelta1'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.004 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'delta1'...
collected 0 docs, 0.0 MB
total 0 docs, 0 bytes
total 0.006 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'tag1'...
ERROR: index 'tag1': id is not a valid attribute name.
total 0 docs, 0 bytes
total 0.001 sec, 0 bytes/sec, 0.00 docs/sec
indexing index 'note1'...
ERROR: index 'note1': id is not a valid attribute name.
total 0 docs, 0 bytes
total 0.001 sec, 0 bytes/sec, 0.00 docs/sec
total 6 reads, 0.000 sec, 0.0 kb/call avg, 0.0 msec/call avg
total 42 writes, 0.001 sec, 0.0 kb/call avg, 0.0 msec/call avg
$ exit
Comments (6)
-
reporter -
reporter The change below allows the index to be created, however I have no idea how it will affect the app.
source tag : base { sql_query_pre = SET NAMES utf8 sql_query = SELECT `_id`, `id` AS id_attr, `uid`, `tag` FROM `tag` sql_attr_uint = id_attr sql_attr_uint = uid }
Using this post as a guide (OLD post) http://sphinxsearch.com/forum/view.html?id=3482
-
reporter Additional info was gained from this post https://www.mail-archive.com/piler-user@list.acts.hu/msg00660.html
To sum up this is what I have done. All changes in sphinx.conf
source tag : base { sql_query_pre = SET NAMES utf8 sql_query = SELECT `_id`, `id` AS id_attr, `uid`, `tag` FROM `tag` sql_attr_uint = id_attr sql_attr_uint = uid } source note : base { sql_query_pre = SET NAMES utf8 sql_query = SELECT `_id`, `id` AS id_attr, `uid`, `note` FROM `note` sql_attr_uint = id_attr sql_attr_uint = uid } searchd { listen = 127.0.0.1:9312 listen = 127.0.0.1:9306:mysql41 log = /dev/null binlog_path = ##query_log = read_timeout = 5 max_children = 30 pid_file = /var/run/piler/searchd.pid max_matches = 1000 seamless_rotate = 1 preopen_indexes = 1 unlink_old = 1 workers = threads # for RT to work #compat_sphinxql_magics = 0 }
- we added field aliasing for the id attribute in both the tag and note base
- we commented out compat_sphinxql_magics
Will this mess up our install of Piler?
-
repo owner I also ran into this problem, and I also tweaked the attribute name to 'iid' (anyway id_attr may sound better), and adjusted the gui code accordingly. So I'd suggest to replace 'id_attr' to 'iid', and it should work. I'll also check the OVA image, thanks for noticing.
-
repo owner -
assigned issue to
-
assigned issue to
-
repo owner - changed status to resolved
I hope everything is ok by now. Otherwise reopen the issue.
- Log in to comment
FYI, I am symlinking /etc/sphinxsearch/sphinx.conf to /usr/local/etc/sphinx.conf.dist, which is installed via make install with piler (I am sure you already new that)