日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > linux >内容正文

linux

linux 卸载sphinx,sphinx管理脚本,实现sphinx启动、关闭、重启、生成索引功能 | linux运维小站–linux系统架构_服务器运维_Linux运维工程师工作手札...

發(fā)布時間:2023/11/30 linux 40 豆豆

最新sphin問題比較多,生成主索引后無法連接上sphinx的,需要重啟searchd進程,為了方便管理sphinx,參考網(wǎng)上資料:http://blog.csdn.net/yagas/article/details/6718532? ?修改一個適合自己的sphinx管理腳本。

[codesyntax lang="bash"]

#!/bin/bash

. /etc/rc.d/init.d/functions

appName="Sphinx"

coreseek_dir="/usr/local/coreseek"

config="/usr/local/coreseek/etc/csft.conf"

stop(){

${coreseek_dir}/bin/searchd -c ${config} --stop > /dev/null 2>&1

ret=$?

if [ $ret -eq 0 ]; then

action $"Stoping $appName: " /bin/true

else

action $"Stoping $appName: " /bin/false

fi

return $ret

}

start(){

${coreseek_dir}/bin/searchd -c ${config} > /dev/null 2>&1

ret=$?

if [ $ret -eq 0 ]; then

action $"Starting $appName: " /bin/true

else

action $"Starting $appName: " /bin/false

fi

return $ret

}

indexer(){

${coreseek_dir}/bin/indexer -c ${config} --all > /dev/null 2>&1

ret=$?

if [ $ret -eq 0 ]; then

action $"$appName making index: " /bin/true

else

action $"$appName making index: " /bin/false

fi

return $ret

}

case $1 in

restart)

stop

start

;;

indexer)

stop

indexer

start

;;

stop)

stop

;;

start)

start

;;

esac

exit 0

[/codesyntax]

總結(jié)

以上是生活随笔為你收集整理的linux 卸载sphinx,sphinx管理脚本,实现sphinx启动、关闭、重启、生成索引功能 | linux运维小站–linux系统架构_服务器运维_Linux运维工程师工作手札...的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。