2014-12-01 2 views
1

메일 퍼 용 스핑크스 검색을 설치해야합니다. 내가 그것을 실행하려고하면 :스핑크스 검색 서비스를 실행하는 중에 오류가 발생했습니다.

[email protected]:/var/log# /etc/init.d/sphinxsearch start 
Starting sphinxsearch: Sphinx 2.0.4-id64-release (r3135) 
Copyright (c) 2001-2012, Andrew Aksyonoff 
Copyright (c) 2008-2012, Sphinx Technologies Inc (http://sphinxsearch.com) 

using config file '/etc/sphinxsearch/sphinx.conf'... 
listening on 127.0.0.1:9312 
listening on 127.0.0.1:9306 
precaching index 'main1' 
precaching index 'main2'          
precaching index 'main3'          
precaching index 'main4'          
precaching index 'dailydelta1'        
precaching index 'delta1'         
precaching index 'tag1'          
precaching index 'note1'          
precached 8 indexes in 0.003 sec        
ERROR. 

로그가 비어 있습니다.

[email protected]:/var/log# ls -al sphinxsearch/ 
total 8 
drwxrwxrwx 2 sphinxsearch root 4096 Oct 21 2013 . 
drwxrwxr-x 11 root   syslog 4096 Dec 1 11:07 .. 

마녀 tail -f /var/log/searchd.log & : 실행중인 것처럼

[email protected]:/var/log# /etc/init.d/sphinxsearch start 
Starting sphinxsearch: Sphinx 2.0.4-id64-release (r3135) 
Copyright (c) 2001-2012, Andrew Aksyonoff 
Copyright (c) 2008-2012, Sphinx Technologies Inc (http://sphinxsearch.com) 

using config file '/etc/sphinxsearch/sphinx.conf'... 
listening on 127.0.0.1:9312 
listening on 127.0.0.1:9306 
precaching index 'main1' 
precaching index 'main2'          
precaching index 'main3'          
precaching index 'main4'          
precaching index 'dailydelta1'        
precaching index 'delta1'         
precaching index 'tag1'          
precaching index 'note1'          
precached 8 indexes in 0.003 sec        
ERROR. 
[email protected]:/var/log# [Mon Dec 1 14:47:38.219 2014] [ 920] Child process 921 has been forked 
[Mon Dec 1 14:47:38.219 2014] [ 921] listening on 127.0.0.1:9312 
[Mon Dec 1 14:47:38.219 2014] [ 921] listening on 127.0.0.1:9306 
[Mon Dec 1 14:47:38.223 2014] [ 921] binlog: replaying log /var/data/binlog/binlog.001 
[Mon Dec 1 14:47:38.223 2014] [ 921] binlog: replay stats: 0 rows in 0 commits; 0 updates; 0 indexes 
[Mon Dec 1 14:47:38.223 2014] [ 921] binlog: finished replaying /var/data/binlog/binlog.001; 0.0 MB in 0.000 sec 
[Mon Dec 1 14:47:38.223 2014] [ 921] binlog: finished replaying total 1 in 0.000 sec 
[Mon Dec 1 14:47:38.223 2014] [ 921] accepting connections 

보이지만 여전히 출력 오류.

답변

0

'ERROR'는 스핑크스에서 온 것 같지 않습니다. 스핑크스가 단순한 오류를 출력하지 않는 경우를 발견 할 수 없습니다. 적어도 설명하려고합니다. init 스크립트의 소스를 확인해보십시오.

'binlog_path'가 올바르게 설정되지 않은 경우 스핑크스는 그런 경험을 통해 알고 있다고 말했지만 실제로는 그렇지 않습니다. 어떤 메시지도없이 대담하게 죽는 경향이 있습니다 (그러나 로그에는 죽기 전에 서버가 시작되는 것으로 표시됩니다).

sphinx.conf에 정의 된 폴더 1) 2)가 폴더로 존재하고 3) sphinxsearch 사용자가 쓰기 가능하다는 것을 확인하십시오. PIDFILE을 찾고 실행

start) 
     echo -n "Starting $DESC: " 
     do_start 
     [ -n "$STARTDELAY" ] && sleep $STARTDELAY 

     if running ; then 
      echo "$NAME." 
     else 
      echo " ERROR." 
     fi 
     ;; 

을 실행 시작 bash는 실행 기능에서 /etc/init.d/sphinxsearch에서

+0

binlog_path를 설정했습니다. 오류는 여전히 동일합니다. 777을 스핑크스가 쓰려고하는 곳으로 설정했습니다. –

+0

그것은 단지 가능한 제안이었습니다. init 스크립트가 그 오류를 출력 할 것인지 (그리고 어떤 조건에서 그렇다면)를 계산할 수 있는지 확인 했습니까? – barryhunter

+0

'실행중인 경우; then echo "$ NAME." else echo "ERROR." fi' –

2

.

running() 
{ 
# Check if the process is running looking at /proc 
# (works for all users) 

    # No pidfile, probably no daemon present 
    [ ! -f "$PIDFILE" ] && return 1 
    # Obtain the pid and check it against the binary name 
    pid=`cat $PIDFILE` 
    running_pid $pid $DAEMON || return 1 
    return 0 
} 

기본 PIDFILE 실행 /의/var 설정/sphinhsearch

PIDFILE=/var/run/sphinxsearch/searchd.pid 

하지만 내 config 파일에서

" using config file '/etc/sphinxsearch/sphinx.conf'...은"PID가 저장되어있는에 " pid_file = /var/run/piler/searchd.pid"

PID 위치를 변경 한 후 " PIDFILE=/var/run/piler/searchd.pid "모두 올바르게 작동합니다.

Starting sphinxsearch: Sphinx 2.0.4-id64-release (r3135) 
Copyright (c) 2001-2012, Andrew Aksyonoff 
Copyright (c) 2008-2012, Sphinx Technologies Inc (http://sphinxsearch.com) 

using config file '/etc/sphinxsearch/sphinx.conf'... 
listening on 127.0.0.1:9312 
listening on 127.0.0.1:9306 
precaching index 'main1' 
precaching index 'main2'          
precaching index 'main3'          
precaching index 'main4'          
precaching index 'dailydelta1'        
precaching index 'delta1'         
precaching index 'tag1'          
precaching index 'note1'          
precached 8 indexes in 0.003 sec        
sphinxsearch.