or wadm --help|-?
or wadm [--user|-u admin-user] [--password-file|-w admin-pswd-file] [--host|-h admin-host] [--port|-p admin-port] [--no-ssl|-N] [--rcfile|-R rcfile]
The Command Line Interface (CLI) enables you to configure and administer Web Server. Use the command line tool wadm to execute the administration commands. The wadm usage is as follows:
wadm --version|-V displays the version of the administration CLI.
wadm --help|-? displays this man page in a text format.
wadm [--user|-u admin-user] [--password-file|-w admin-pswd-file] [--host|-h admin-host] [--port|-p admin-port] [--no-ssl|-N] [--rcfile|-R rcfile] launches wadm in a shell mode.
You can invoke wadm in stand-alone mode, shell mode, or file mode.
Stand-alone mode — In the stand-alone mode, you can directly invoke the CLI specifying the desired command, options, and operands. On completion of a command, the CLI returns back to the shell. The stand-alone mode supports both interactive and non-interactive execution of commands. Interactive execution, which is the default, prompts for the passwords if not already specified in the command or password-file. Non-interactive execution executes a command without prompting for passwords. You must specify the user and password-file options for every command that you execute in the stand-alone mode.
Example for stand-alone mode:
$ wadm list-configs --user=admin --host=serverhost --password-file=./admin.pwd
Shell mode — In the shell mode, you can invoke the CLI from a shell that is embedded within wadm. On completion of the command, the CLI returns back to the shell. You can exit the shell by typing exit or quit. The shell mode supports both interactive and non-interactive execution of command. This mode accepts user and password-file when you invoke wadm.
Example for shell mode:
$ wadm --user=admin --password-file=./admin.pwd
Oracle iPlanet Web Server 7.0.9 20:35
File mode — In the file mode, you can create a commands-file containing a list of valid commands. The file mode accepts user and password-file when you invoke wadm.
Example for file mode:
$ cat sample.tcl set wadm::command false set x [list-configs] puts $x
$ wadm --user=admin --password-file=./admin.pwd --commands-file=sample.tcl
where sample.tcl is the name of the commands-file.
To get help on wadm, type wadm -help
To get help on any specific command, type
wadm sub-command --help
For example, $ wadm add-documents --help
Use the connect_options to connect to the Administration Server. Connect_options include administration user name, password file, host, port (SSL/non-SSL) and an optional preferences file. These options are common for all commands. In the shell mode, the connect_options that you provide while invoking wadm are automatically used for every command that you execute.
A list of connect_options and description is as follows:
[--user|-u admin-user] [--password-file|-w admin-pswd-file] [--host|-h admin-host] [--port|-p admin-port] [--no-ssl|-N] [--rcfile|-R rcfile]
Optional arguments (or options) are displayed within square brackets , for example, [-user|-u].
Specify the user name of the authorized Web Server administrator.
Specify the name and the location of the password file. The password file contains the password to authenticate administrators to the Administration Server. Apart from the administration password, you can also specify other passwords such as bind-password, user-password, keystore-password, token-pin, and so on. If you do not specify this option, you will be prompted for a password while executing the command.
A sample password file is as follows:
wadm_password=wadm-password wadm_bind_password=bind-password wadm_user_password=user-password wadm_token_pin=token-pin wadm_keystore_password=keystore-password wadm_key_password=key-password wadm_new_token_pin=new-token-password wadm_admin_password=admin-password wadm_<token_name>=token-pin
wadm_<token_name> is applicable only for the start-instance command. You can use wadm_<token_name> to set multiple token pins to start instances on multiple nodes.
For example, a default token named internal is configured for any instance. The entry for the default token in the password-file will be wadm_internal=88888888.
Specify the name of the machine where the Administration Server is running. The default host is localhost.
This option is required only if you are connecting to Administration Server remotely.
Specify the port number of the Administration Server. The default non-SSL port is 8800 and the default SSL port is 8989.
If you are invoking the CLI from an Administration Server installation, port numbers (SSL port value by default or non-SSL port value if the --no-ssl option is specified) are automatically picked up.
Specify this option to use a plain text connection to communicate with the Administration Server. The default connection is SSL.
Specify the name of the rcfile that has to be loaded while starting wadm. The default file is .wadmrc. The .wadmrc file is a TCL file that gets loaded before any command is executed. You can use the long options as variables by changing the hyphen (-) in the option name to underscore (_) and prefixing it with wadm. For example:
--config can be set as set wadm_config config1
--key-type can be set as set wadm_key_type ecc
A sample .wadmrc is as follows:
set wadm_config sampleconfig set wadm_password mypassword set wadm_nodehost sample.sun.com
You can also set the following wadm variables to modify the overall behavior of wadm:
wadm::command: (Applicable only in the file mode.) Enables you to output all commands to stdout and stderr. If set to true, exceptions do not stop the execution of commands, rather they are printed in the stdout and the next command is executed. You can set this variable in the commands-file.
$ cat commands.tcl set wadm::command true set x [list-configs] puts $x
where commands.tcl is the name of the commands-file.
wadm::savehist: (Applicable only in the shell mode.) If set to true, all wadm commands that you execute are saved in the wadm::histfile file. The wadm::histfile is saved in your home directory. You can set this variable in the wadm environment using the wadm> set wadm::savehist true command:
wadm::file: This is set to true if you are executing the wadm commands in the file mode.
wadm::tokenize: If set to true, wadm parses the log files in a TCL friendly format.
wadm::log_date_format: Use this variable to define the date format in the log files. The default format is MM/dd/yyyy:HH:mm:ss.
wadm::date_format: Use this variable to define a date format in which a user can enter a date. The default value is the date format of the current locale.
wadm::property_separator: Use this variable to define the property separator. The default value is the equal to (=) symbol. For example, wadm>set wadm::property_separator :
wadm::field_separator: Use this variable to define the field or column separator. The default value is a blank space ( ). For example, wadm>set wadm::field_separator |
wadm::field_format: Use this variable to define the display format of a field or column. The default value is %-15s. For example, wadm>set wadm::field_format %-15s|
The following exit codes are returned:
0 — command executed successfully
1–4 — connection failure errors
10–22 — parsing errors
33–43 — input/output errors
44–56 — general errors, for example, invalid configuration value
76–96 — generic back-end errors
110–123 — errors that are specific to Mbeans
125 — unknown errors