2016-07-27 24 views
0

在使用systemctl運行我的應用程序時遇到此錯誤其中systemserl啓動時出現systemctl錯誤的問題實際上存在問題?systemctl在運行systemctl start時出錯<application>

Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Started <application> Web Interface. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Main process exited, code=exited, status=203/EXEC 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Unit entered failed state. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Failed with result 'exit-code'. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Service hold-off time over, scheduling restart. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Stopped <application> Web Interface. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Started <application> Web Interface. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Main process exited, code=exited, status=203/EXEC 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Unit entered failed state. 
Jul 27 16:20:36 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Failed with result 'exit-code'. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Service hold-off time over, scheduling restart. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Stopped <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Started <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Main process exited, code=exited, status=203/EXEC 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Unit entered failed state. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Failed with result 'exit-code'. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Service hold-off time over, scheduling restart. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Stopped <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Started <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Main process exited, code=exited, status=203/EXEC 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Unit entered failed state. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Failed with result 'exit-code'. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Service hold-off time over, scheduling restart. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Stopped <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Started <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Main process exited, code=exited, status=203/EXEC 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Unit entered failed state. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Failed with result 'exit-code'. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Service hold-off time over, scheduling restart. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Stopped <application> Web Interface. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: <application>.service: Start request repeated too quickly. 
Jul 27 16:20:37 nikhil-Lenovo-ideapad-300-15ISK systemd[1]: Failed to start <application> Web Interface. 

回答

0

服務單位的文件應該設置一個RestartSec,大多數開發人員忘了這一點。

Restart=on-failure 
RestartSec=3 
相關問題