12 Replies Latest reply on Jul 1, 2008 6:02 AM by gan.gary

    JBoss as window service

    gan.gary Novice

      I tried to set JBoss as window service("jboss-native-2.0.4-windows-x86-ssl.zip" as describe at:
      http://wiki.jboss.org/wiki/JBossNativeWindows
      But I get this error, why?

      The JBoss Application Server 5.0 service could not be started.
      The service did not reprot an error.
      More help is available by typing NET HELPMSG 3534


      when i do this "NET HELPMSG 3534", I get:

      The service did not reprot an error.


      How? I am using "jboss-4.2.2.GA" for dev, it's 94MB, but the service mentioned only 1MB?

        • 1. Re: JBoss as window service
          jaikiran pai Master

          What does the run.log in the %JBOSS_HOME%/bin folder show?

          • 2. Re: JBoss as window service
            Peter Johnson Master

            Where do you have JAVA_HOME defined? In the User Variables or the System Variables? It has to be set in System Variables.

            What account are you using for the service? If you set up a special account, did you make sure that account has read/write access to all of the JBossAS files and directories?

            • 3. Re: JBoss as window service
              gan.gary Novice

               

              "jaikiran" wrote:
              What does the run.log in the %JBOSS_HOME%/bin folder show?


              why I get this at error log?

              Starting JBoss Application Server 5.0 [2008-06-30 08:49:38]
              'run.bat' is not recognized as an internal or external command,
              operable program or batch file.
              Shutdown JBoss Application Server 5.0 service [2008-06-30 08:49:38]


              • 4. Re: JBoss as window service
                gan.gary Novice

                 

                "PeterJ" wrote:
                Where do you have JAVA_HOME defined? In the User Variables or the System Variables? It has to be set in System Variables.


                System Variables:
                C:\Program Files\Java\jdk1.5.0_15


                "PeterJ" wrote:
                What account are you using for the service? If you set up a special account, did you make sure that account has read/write access to all of the JBossAS files and directories?

                Computer admin. Should have full access right.

                • 5. Re: JBoss as window service
                  gan.gary Novice

                  For this:

                  Starting JBoss Application Server 5.0 [2008-06-30 08:49:38]
                  'run.bat' is not recognized as an internal or external command,
                  operable program or batch file.
                  Shutdown JBoss Application Server 5.0 service [2008-06-30 08:49:38]

                  I found there's no run.bat at "jboss-native-2.0.4-windows-x86-ssl.zip", even If I extract to "C:\jboss-5.0.0".

                  it only can run when I issue this at command prompt:
                  call %JBOSS_HOME%/bin/run.bat

                  • 6. Re: JBoss as window service
                    gan.gary Novice

                    and %JBOSS_HOME% = C:\jboss\jboss-4.2.2.GA

                    • 7. Re: JBoss as window service
                      jaikiran pai Master

                       


                      Starting JBoss Application Server 5.0 [2008-06-30 08:49:38]
                      'run.bat' is not recognized as an internal or external command,
                      operable program or batch file.


                      Where did you extract the JBossNative zip file? It should be extracted to the %JBOSS_HOME% folder. The JBoss Native has a bin folder which copies new files to the %JBOSS_HOME%/bin folder. Ultimately, the service.bat file should be present in the %JBOSS_HOME%/bin folder.



                      System Variables:
                      C:\Program Files\Java\jdk1.5.0_15


                      I would recommend that you move the JDK installation to a folder which does not have a space in its path. JBoss or Java installations in folders having space in their path name run into weird issues. I have my Java installation at C:\jdk1.5.0_15




                      • 8. Re: JBoss as window service
                        gan.gary Novice

                         

                        "jaikiran" wrote:

                        Starting JBoss Application Server 5.0 [2008-06-30 08:49:38]
                        'run.bat' is not recognized as an internal or external command,
                        operable program or batch file.


                        Where did you extract the JBossNative zip file? It should be extracted to the %JBOSS_HOME% folder. The JBoss Native has a bin folder which copies new files to the %JBOSS_HOME%/bin folder. Ultimately, the service.bat file should be present in the %JBOSS_HOME%/bin folder.


                        OMG, I follow the "README-service.txt":
                        To install the JBoss Application Server as Windows service use
                        the provided service.bat batch file.
                        C:\> cd c:\jboss-5.0.0\bin
                        C:\> service.bat install

                        You meant copy the content of "jboss-native-2.0.4-windows-x86-ssl\bin" to %JBOSS_HOME%/bin? what about content of "jboss-native-2.0.4-windows-x86-ssl\licenses"?


                        "jaikiran" wrote:

                        System Variables:
                        C:\Program Files\Java\jdk1.5.0_15


                        I would recommend that you move the JDK installation to a folder which does not have a space in its path. JBoss or Java installations in folders having space in their path name run into weird issues. I have my Java installation at C:\jdk1.5.0_15


                        I knew old JDK has this issue, I thought the JDK 1.5 have fixed it, that's why the installer pointed to that folder?

                        • 9. Re: JBoss as window service
                          jaikiran pai Master

                           

                          You meant copy the content of "jboss-native-2.0.4-windows-x86-ssl\bin" to %JBOSS_HOME%/bin?


                          Yes.


                          what about content of "jboss-native-2.0.4-windows-x86-ssl\licenses"?


                          This is something i have seen in the latest version of JBoss Native. The earlier versions did not have this folder. Looks like there's been some more changes to the packaging too (no more "native" folder). The ReadMe doesn't mention much about the licenses. I would just copy over the licenses folder to the %JBOSS_HOME% folder. Here's how my installation of the latest JBoss Native version on JBoss-4.2.2 GA looks like:
                          JBoss-4.2.2 GA
                           |
                           |
                           |--- bin
                           | |
                           | |
                           | |--- META-INF (extracted from the JBoss Native download)
                           | |
                           | |
                           | |--- jbosssvc.exe (extracted from the JBoss Native download)
                           | |
                           | |
                           | |--- <some other files from JBoss Native download)
                           | |
                           | |
                           | |--- licenses (extracted from the JBoss Native download)
                           | |
                           | |
                           | |--- run.bat (from JBoss Application Server)
                           | |
                           | |
                           | |--- <some more files from JBoss Application Server)





                          • 10. Re: JBoss as window service
                            jaikiran pai Master

                            Small correction:

                            JBoss-4.2.2 GA
                             |
                             |
                             |--- bin
                             | |
                             | |
                             | |--- META-INF (extracted from the JBoss Native download)
                             | |
                             | |
                             | |--- jbosssvc.exe (extracted from the JBoss Native download)
                             | |
                             | |
                             | |--- <some other files from JBoss Native download)
                             | |
                             | |
                             | |
                             | |--- run.bat (from JBoss Application Server)
                             | |
                             | |
                             | |--- <some more files from JBoss Application Server)
                             |
                             |
                             |--- licenses (extracted from the JBoss Native download)
                            


                            • 11. Re: JBoss as window service
                              gan.gary Novice

                              great, thanks!

                              BTW, do you have any idea on failover cluster? I posted post on that section but no one reply.

                              While trying to setup a new JBoss apps, I come across with failover clustering, does anyone have any advices on this, other than the link at Jboss doc: Chapter 16. Clustering http://docs.jboss.org/jbossas/jboss4guide/r4/html/cluster.chapt.html
                              & http://wiki.jboss.org/wiki/JBossHA ?
                              Any simple hello world exmple?
                              Or anyone know this: http://wiki.jboss.org/wiki/BasicClusterTest ?
                              It seems simple but nothing there.


                              • 12. Re: JBoss as window service
                                gan.gary Novice

                                thanks! you help me to solve the problem.