Run Java Program As Daemon Service Following Guide Not Working ?? (RHEL 5)

末鹿安然 提交于 2019-12-13 08:46:37

问题


I am trying to run the program as mentioned here: http://www.source-code.biz/snippets/java/7.htm

while running the following command, I see error:

./javaDaemonTest.sh install

The error is as follows

./javaDaemonTest.sh: line 29: .: /etc/rc.status: is a directory
./javaDaemonTest.sh: line 193: rc_reset: command not found
ln: creating symbolic link `/usr/local/sbin/rcjavaDaemonTest' to `/var/local/javaDaemonTest/javaDaemonTest.sh': File exists
./javaDaemonTest.sh: line 221: rc_exit: command not found

How to debug it? Or, if you are following this guide, are you getting this error? My JAVA_HOME path is set correctly.


回答1:


The line 29 is

  . /etc/rc.status 

Which indicates it should have been a file. The script may be specific to SUSE (SLES). What is your OS/distribution? You are better off with trying the solution outlined in the same link..



来源:https://stackoverflow.com/questions/8998543/run-java-program-as-daemon-service-following-guide-not-working-rhel-5

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!