Skip to content

Instantly share code, notes, and snippets.

@liuanyou
Last active September 12, 2017 05:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save liuanyou/7d49fd98d0f70370c71dcb34579807fc to your computer and use it in GitHub Desktop.
Save liuanyou/7d49fd98d0f70370c71dcb34579807fc to your computer and use it in GitHub Desktop.
GlassFish asadmin commands
  1. Install GlassFish Server 4.0
  2. Run Command Line window as administrator
  3. Type

    cd <GlassFish_Home>/bin

Create domain

asadmin create-domain <domain_name>

Delete domain

asadmin delete-domain <domain_name>

Start domain

asadmin start-domain <domain_name>

Stop domain

asadmin stop-domain <domain_name>

Change administrator password

asadmin change-admin-password

Enable remote management

asadmin enable-secure-admin

Disable remote management

asadmin disable-secure-admin

Create windows service

It will create <domain_name>Service.exe under <GlassFish_Home>/domains/<domain_name>/bin directory

asadmin create-service <domain_name>

Start windows service

<domain_name>Service.exe start

Stop windows service

<domain_name>Service.exe stop

Restart windows service

<domain_name>Service.exe restart

Uninstall windows service

<domain_name>Service.exe uninstall

Install windows service

<domain_name>Service.exe install

Check windows service status

<domain_name>Service.exe status

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment