运行命令如下 1.systemctl stop travel.service 2.systemctl start travel.service 3.systemctl status travel.service 启动失败信息: ?.travel.service - travel Loaded: loaded (/etc/systemd/system/travel.service; disabled; vendor preset: disabled) Active: failed (Result: exit-code) since Wed 2019-10-16 19:19:58 CST; 5s ago Process: 15269 ExecStart=/data/travel/run.sh (code=exited, status=203/EXEC) Main PID: 15269 (code=exited, status=203/EXEC)
Oct 16 19:19:58 iz2zeeopz0eivjpvx28fhwz systemd[1]: Started travel. Oct 16 19:19:58 iz2zeeopz0eivjpvx28fhwz systemd[1]: travel.service: main process exited, code=exited, status=203/EXEC Oct 16 19:19:58 iz2zeeopz0eivjpvx28fhwz systemd[1]: Unit travel.service entered failed state. Oct 16 19:19:58 iz2zeeopz0eivjpvx28fhwz systemd[1]: travel.service failed.
travel.service: [Unit] Description=travel After=travel.service
[Service] ExecStart=/data/travel/run.sh ExecReload=/data/travel/run.sh
[Install] WantedBy=multi-user.target
run.sh: #!/bin/sh cd /data/travel java -jar travelApi-0.0.1-SNAPSHOT.jar
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。