我下載了ElasticSearch,運行bin/elasticsearch.bat
,它在我的本地計算機上運行。然後,我添加了elasticsearch文件夾到我的資料庫,並更新了deploymentscript(deploy.cmd),加上幾行:無法在Azure WebApp中啓動ElasticSearch
starting ElasticSearch...
Error occurred during initialization of VM
Error: Could not create the Java Virtual Machine.
Could not reserve enough space for object heap
Error: A fatal exception has occurred. Program will exit.
:
echo starting ElasticSearch...
elasticsearch-1.7.2\bin\elasticsearch.bat
echo ElasticSearch started!
推我的倉庫到我的Azure的網站後,在日誌中出現此錯誤
在我的WebApp的配置中打開了Java。所以有什麼問題?爲什麼不能創建Java VM?
編輯:Could not reserve enough space for object heap
看起來像我有較少的內存,但我已經嘗試過了3.5GB與RAM和該錯誤也出現 - ElasticSearch只是我的本地機器上使用155 MB RAM)
EDIT2: 經過一番嘗試我得到一個新的錯誤日誌:
starting ElasticSearch...
[2015-10-15 12:59:18,879][INFO ][node ] [Marsha Rosenberg] version[1.7.2], pid[3728], build[e43676b/2015-09-14T09:49:53Z]
[2015-10-15 12:59:18,879][INFO ][node ] [Marsha Rosenberg] initializing ...
[2015-10-15 12:59:19,273][INFO ][plugins ] [Marsha Rosenberg] loaded [], sites []
[2015-10-15 12:59:20,692][INFO ][env ] [Marsha Rosenberg] using [1] data paths, mounts [[Windows (D:)]], net usable_space [13.5gb], net total_space [32gb], types [NTFS]
[2015-10-15 12:59:28,869][INFO ][node ] [Marsha Rosenberg] initialized
[2015-10-15 12:59:28,869][INFO ][node ] [Marsha Rosenberg] starting ...
{1.7.2}: Startup Failed ...
- ChannelException[Failed to create a selector.]
IOException[Unable to establish loopback connection]
SocketException[Address family not supported by protocol family: bind]
謝謝!我編輯了elasticsearch配置文件,以便它現在監聽端口80(適用於本地計算機),但在我的WebApp部署中出現同樣的錯誤。我已經在ES上使用了一個虛擬機,但是我想遷移到WebApp,因爲我不想像VM那樣擁有高維護。我將介紹一下Azure搜索,但我更喜歡WebApp中的ES。 – Munchkin
@Munchkin Azure WebApp包含IIS代理,用於Java的Tomcat或Jetty Servlet容器,以及WebJob作爲沒有http偵聽器的後端任務。它不適合獨立的服務流程。部署腳本僅用於將Web項目部署到Azure中,而不用於啓動服務。因此,如果您不想爲ES使用虛擬機,我建議您在Azure預覽門戶市場中免費使用Facetflow ES。感謝您的反饋意見。關於Azure上關於ES的任何問題,請隨時通知我。 –