I tried to start this from administrative tools -> Service But could not. On command prompt I tried MyService //TS//MyService which is used ot run service from commandline. I am gettting error:
Service 'MyService1' is missing the ImageFile
I googled it. somewhare I found that if I copy msvcr71.dll from jdk/jre/bin to system32 directory the problem will be solved. But it didnot work.
Please do help at the earliest.
I am getting following Error message along with one warning :
[2011-07-21 10:04:19] [warn] The system cannot find the Registry key for servic
e 'MyService1'
[2011-07-21 10:04:19] [error] Load configuration failed
[2011-07-21 10:04:19] [error] The system cannot find the file specified.
[2011-07-21 10:04:19] [error] Commons Daemon procrun failed with exit value: 2 (
Failed to load configuration)
[2011-07-21 10:04:19] [error] The system cannot find the file specified.
please give some solution at the earliest..
priyas sakorikar
Greenhorn
Joined: May 23, 2008
Posts: 7
posted
0
Hi,
I have done some thing funny.. but it removed previous error/s.But now got ClassnotFoundException
this is what i have done :
I copied prunsrv.exe,prunsrvmgr.exe,msvcr71.dll jvm.dll,rt.jar,java.exe to the same folder where my application is available.Now i executed this with
This is what I am getting now:
C:\Prv>Service //TS//Service
java.lang.NoClassDefFoundError: myService1/MyService1
Caused by: java.lang.ClassNotFoundException:myService1/MyService1
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: p.Service. Program will exit.
Exception in thread "main"
It is like unable to solve this. Please ignite my mind.
Could you point me to some documentation for myservice1.exe, or tell me where to download it from? I am not familiar with it, and thus can be of little help.
priyas sakorikar
Greenhorn
Joined: May 23, 2008
Posts: 7
posted
0
myService1.exe is nothing but prunsrv.exe which is from Apache foundation. prunsrv.exe can be renamed if required. Tomcat.exe which we use is the same prunsrv.exe with name changed to Tomcat.
prunsrv is used to create daemon.I am trying to make my application MyService1.java-> MyService1.class as a windows application.
You can find more information for this on Prunsrv site.