2017-02-13 125 views
0

我試圖啓動Solr PHP的服務。 我跑bin/solr start -f 但我發現了這樣的警告:運行Solr PHP無法啓動服務

Starting Solr as the root user is a security risk and not considered best practice. Exiting.

Please consult the Reference Guide. To override this check, start with argument '-force'

所以我在bin/solr -force start -f添加-force部分。 但即使如此,我只是得到這個錯誤:

ERROR: start is not supported by this script

我只是不能啓動該服務。

回答

0

您將需要設置Solr的目錄將要開始的Solr用戶的權限(這不應該是root)

運行chown -R <username> <solrDir>與你相關的值(例如chown -R ghost /opt/solr)替代變量,然後以該用戶開始solr。