2014-10-09 40 views
3

當我把我的應用程序在Openshift它被上傳和最後消息是如何解決openshift上的jbossews:無法執行:'控制重啓'?

remote: Starting jbossews cartridge 
remote: jbossews process failed to start 
remote: Git Post-Receive Result: failure 
remote: Activation status: failure 
remote: Activation failed for the following gears: 
remote: 5433a24de0b8cd0dfa----- (Error activating gear: CLIENT_ERROR: 
Failed to execute: 'control start' for 
/var/lib/openshift/5433a24de0b8cd0dfa0000ec/jbossews) 

remote: Deployment completed with status: failure 
remote: postreceive failed 

此外,當我手動重新從Openshift網站上的應用程序,它向我展示

"Unable to complete the requested operation" 
"Starting jbossews cartridge 
jbossews process failed to start 
The jbossews cartridge is already stopped 
Failed to execute: 'control restart' for /var/lib/openshift/5433a24de0b8cd0dfa-----/jbossews" 

你將如何解決此錯誤信息?

回答

2

關鍵的錯誤信息是「postreceive failed」:您需要檢查您的應用程序爲什麼沒有正確部署。

你會在this thread找到一個例子:

您的項目不具有一個Maven基於項目的正確結構。
嘗試創建一個jboss ews 2的齒輪,然後git clone從那裏的文件並檢查結構。
如果您想使用--from-code選項,它需要具有該結構。包括pom.xml與openshift配置文件。
您可以在此瀏覽正確的結構:origin-server/cartridges/openshift-origin-cartridge-jbossews/template

如果您只是想將應用程序打包爲war文件,並將其添加到webapps目錄中,則可以刪除src目錄和pom.xml文件並執行該操作。

您應該能夠輕鬆地將您的項目移動到正確的結構中。

+0

我已經刪除了pom.xml和src文件夾。這仍然在發生。 – 2014-10-09 07:23:08

+0

@MohanKumarBai我明白了。也許再看看模板項目,看看你是否可以部署它(然後修改它以包含你自己的源代碼)。 – VonC 2014-10-09 07:25:34

+0

爲什麼發生這種情況?這是我的應用程序問題或配置問題或openshift有這個問題嗎? – 2014-10-09 09:43:37

0

對我來說,我注意到the template repo和我自己的有點不同。

首先,我沒有創建一個webapps文件夾,其中.gitkeep。其次,我需要Java 7並且沒有創建文件.openshift/markers/java7(我還沒有意識到Java 6是默認使用的)。

做完這兩件事後,部署爲我工作。

4

由於許多不同的問題,可能會發生這種情況。您可以嘗試查看日誌以查看發生了什麼問題:

rhc tail -a myapp 
相關問題