Use the asadmin utility to perform any administrative task for the Sun Java System Application Server. You can use this utility in place of using the Administrator interface.
The subcommand identifies the operation or task you wish to perform. Subcommands are case-sensitive. Short option arguments have a single dash (-); while long option arguments have two dashes (--). Options modify how the utility performs a subcommand.
Options are also case-sensitive. Most options require argument values except boolean options which toggle to switch a feature ON or OFF. Operands appear after the argument values, and are set off by a space, a tab, or double dashes (--). The asadmin utility treats anything that
comes after the options and their values as an operand.
Local subcommands can be executed without the presence of an administration server. However, it is required that the user be logged into the machine hosting the domain in order to execute the subcommand and have access (permissions) for the installation and domain directories.
Remote subcommands are always executed by connecting to an administration server and executing the subcommand there. A running administration server is required. All remote subcommands require the following options:
- -u --user
- authorized domain application server administrative username.
- -w --password
- password to administer the domain application server.
- -H --host
- machine name where the domain application server is running.
- -p --port
- port number of the domain application server listening for administration requests.
- -s --secure
- if true, uses SSL/TLS to communicate with the domain application server.
- -t --terse
- indicates that any output data must be very concise, typically avoiding human-friendly sentences and favoring well-formatted data for consumption by a script. Default is false.
- -e --echo
- setting to true will echo the command line statement on the standard output. Default is false.
- -I --interactive
- if set to true (default), only the required password options are prompted.
For security purposes, you can set the password for a subcommand from a file instead of entering the password at the command line. The --passwordfile option takes the file containing the passwords. The valid contents for the file are:
Given the --passwordfile option and its value, the password options in the passwordfile are exported to the global environment; subsequent subcommands without the password options take this value. However, if both the --password and --passwordfile options are specified on the command line, the password value in the passwordfile is exported to the global environment and subsequent subcommands without the --password option would take this value. However, for the current subcommand,
the --password option value specified on the command line is taken since the --password option takes precedence over the --passwordfile option.
To use the --secure option, you must use the set command to enable the security--enabled flag in the admin http-listener in the domain.xml.
When you use the asadmin subcommands to create and/or delete, you must restart the server for the newly created command to take affect. Use the start-domain command to restart the server.
To access the manpages for the Sun Java System Application Server Command-line interface subcommands, add $AS_INSTALL/man to your MANPATH environment variable.
You can obtain overall usage information for any of the asadmin utility subcommands by invoking the --help option. If you specify a subcommand, the usage information for that subcommand is displayed. Using the help option without a subcommand
displays a listing of all the available subcommands.