Ubuntu 14.04安裝,帶有nginx,passenger和postgresql。以下步驟執行:通過MySQL的thinking_sphinx連接
sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get install mysql-server
sudo mysql_secure_installation _for allowing only localhost connection_
sudo apt-get install sphinxsearch
寶石文件有
gem 'mysql2', '0.3.18', :platform => :ruby
gem 'thinking-sphinx', '3.1.4'
thinking_sphinx.yml指定
mysql41: 9312
運行:
RAILS_ENV=development bundle exec rake ts:rebuild
繼續正確:total 112 writes, 0.079 sec, 485.0 kb/call avg, 0.7 msec/call avg Started searchd successfully (pid: 21644).
netstat -ltnp
只顯示一個searchd的過程
tcp 0 0 127.0.0.1:9312 0.0.0.0:* LISTEN 21644/searchd
這樣一個結論,一切都是去......吧? [討厭的蜂鳴器]
ThinkingSphinx::ConnectionError
Error connecting to Sphinx via the MySQL protocol.
Error connecting to Sphinx via the MySQL protocol. _nice... stated twice!_
Can't connect to MySQL server on '127.0.0.1' (111)
面向非連接的可能的途徑:
- 的MySQL服務器root密碼不被消化
- nginx的莫名其妙阻礙的連接
別人呢?如何驗證/斷言?
您是否試圖保護與Sphinx的MySQL協議連接?或者對於Sphinx連接的MySQL數據庫? – pat
保護MySQL協議連接。數據庫是postgreSQL。 – Jerome