遵循指南,将Java程序作为守护程序服务运行不起作用? (RHEL 5) [英] Run Java Program As Daemon Service Following Guide Not Working ?? (RHEL 5)

查看:138
本文介绍了遵循指南,将Java程序作为守护程序服务运行不起作用? (RHEL 5)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试运行此处提到的程序: http://www .source-code.biz/snippets/java/7.htm

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

错误如下

./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

如何调试它?或者,如果您遵循本指南,是否会收到此错误?我的JAVA_HOME路径设置正确.

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

推荐答案

第29行是

  . /etc/rc.status 

这表明它应该是一个文件.该脚本可能特定于SUSE(SLES).您的操作系统/发行版是什么?您最好尝试使用同一链接中概述的解决方案.

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..

这篇关于遵循指南,将Java程序作为守护程序服务运行不起作用? (RHEL 5)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆