2013-04-26 65 views
2

我在opensuse 12.2/64上安裝了neo4j 1.8.2。要做到這一點我不得不添加在/etc/profile文件作爲JAVA_HOME路徑:現在,當我嘗試檢查服務器狀態,我得到以下錯誤neo4j在檢查服務狀態時找不到JAVA_HOME

export JAVA_HOME=/opt/java/64/jdk1.7.0_21/jre/: 
export PATH=$PATH:/opt/java/64/jdk1.7.0_21/jre/bin/; 

>service neo4j-service status 

    neo4j-service.service - LSB: The Neo4J graph database server. See http://neo4j.org 
       Loaded: loaded (/etc/init.d/neo4j-service) 
       Active: failed (Result: exit-code) since Fri, 26 Apr 2013 17:13:56 +0200; 10s ago 
      Process: 7234 ExecStart=/etc/init.d/neo4j-service start (code=exited, status=1/FAILURE) 
       CGroup: name=systemd:/system/neo4j-service.service 

    Apr 26 17:13:56 linux-wwcz neo4j-service[7234]: which: no java in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/...bin) 
    Apr 26 17:13:56 linux-wwcz neo4j-service[7234]: Error: JAVA_HOME is not defined correctly. 
    Apr 26 17:13:56 linux-wwcz neo4j-service[7234]: We cannot execute 

這是頗令人費解考慮neo4j-service鏈接到./bin/neo4j,即所使用的文件在安裝時與

./bin/neo4j install 

對什麼是這裏發生了一些想法?

感謝

解決

其實我用的是JDK 7,而不是JDK 6

EDIT 2

根據官方的Neo4j頁面一個運行在服務器使用neo4j start。但是我試圖運行service neo4j start/status/stop時遇到了麻煩,如Installing Neo4j in Linux的操作方法。

回答

1

他們嘗試更改爲此:

export JAVA_HOME=/opt/java/64/jdk1.7.0_21/: 
export PATH=$PATH:/opt/java/64/jdk1.7.0_21/bin/; 
+0

謝謝回答。其實它並沒有解決問題。我再次經歷了安裝過程,但當我檢查服務器狀態時,我仍然收到相同的錯誤。 – user17375 2013-04-26 15:58:19