Search code examples
serviceglassfish-3

Error creating glassfish as a service


Trying to do: asadmin create-service

And getting:

Error while trying to install Glassfish as a Windows Service.
The return value was: 8.
STDERR:
STDOUT: WMI.WmiException: UnknownFailure
at WMI.WmiRoot.BaseHanderl.CheckError(ManagementBaseObject result)
at WMI.WmiRoot.ClassHandler.Invoke(Object proxy, MethodInfo method, Object[] ags)
at WMI.Win32ServicesProxy.Create(String, String, STring, ServiceType, ErrorControl, StartMode, Boolean, String[])
at winsw.WrapperService.Run(String[] args)
at winsw.WrapperService.Main(String[] arges

Command create-service failed

Trying to create glassfish as a service to start glassfish at windows boot (with a WAR file in the auto-deploy folder to start the application ASAP.)


Solution

  • do you have more than one domain in your domain directory? if so you must specify the name of the domain as noted in the asadmin create-service documentation