Previous Next Contents


adds a new HTTP network listener socket


asadmin [asadmin-options] create-http-listener [--help]
--listeneraddress address
--listenerport listener-port
{--default-virtual-server | --defaultvs} virtual-server
[--servername server-name]
[--acceptorthreads acceptor-threads]
[--redirectport redirect-port]
[--target target]


The create-http-listener subcommand creates an HTTP network listener. This subcommand is supported in remote mode only.


If you edit the special HTTP network listener named admin-listener, you must restart the server for the changes to take effect. The Administration Console does not tell you that a restart is required in this case.


This subcommand is provided for backward compatibility and as a shortcut for creating network listeners that use the HTTP protocol. Behind the scenes, this subcommand creates a network listener and its associated protocol, transport, and HTTP configuration.



Options for the asadmin utility. For information about these options, see the asadmin(1M) help page.


Displays the help text for the subcommand.


The IP address or the hostname (resolvable by DNS).


The port number to create the listen socket on. Legal values are 1-65535. On UNIX, creating sockets that listen on ports 1-1024 requires superuser privileges. Configuring an SSL listen socket to listen on port 443 is recommended.


The ID attribute of the default virtual server for this listener. The --defaultvs option is deprecated.


Tells the server what to put in the host name section of any URLs it sends to the client. This affects URLs the server automatically generates; it doesn’t affect the URLs for directories and files stored in the server. This name should be the alias name if your server uses an alias. If a colon and port number are appended, that port will be used in URLs that the server sends to the client.


The number of acceptor threads for the listener socket. The recommended value is the number of processors in the machine. The default value is 1.


If set to true, adds the X-Powered-By: Servlet/3.0 and X-Powered-By: JSP/2.0 headers to the appropriate responses. The Servlet 3.0 specification defines the X-Powered-By: Servlet/3.0 header, which containers may add to servlet-generated responses. Similarly, the JSP 2.0 specification defines the X-Powered-By: JSP/2.0 header, which containers may add to responses that use JSP technology. The goal of these headers is to aid in gathering statistical data about the use of Servlet and JSP technology. The default value is true.


Do not specify this option. This option is retained for compatibility with earlier releases. If you specify this option, a syntax error does not occur. Instead, the subcommand runs successfully and displays a warning message that the option is ignored.


If set to true, the HTTP listener runs SSL. You can turn SSL2 or SSL3 ON or OFF and set ciphers using an SSL element. The security setting globally enables or disables SSL by making certificates available to the server instance. The default value is false.


If set to true, the listener is enabled at runtime. The default value is true.


Creates the HTTP listener only on the specified target. Valid values are as follows:


Creates the HTTP listener on the default server instance. This is the default value.


Creates the HTTP listener in the specified configuration.


Creates the HTTP listener on all server instances in the specified cluster.


Creates the HTTP listener on the specified standalone server instance.



The listener ID of the HTTP network listener.


Example 1   Creating an HTTP Network Listener

The following command creates an HTTP network listener named sampleListener that uses a nondefault number of acceptor threads and is not enabled at runtime:

asadmin> create-http-listener --listeneraddress --listenerport 7272
--defaultvs server --servername --acceptorthreads 100
--securityenabled=false --enabled=false sampleListener
Command create-http-listener executed successfully.

Exit Status


command executed successfully


error in executing the command

See Also

Previous Next Contents
Eclipse Foundation Logo  Copyright © 2019, Oracle and/or its affiliates. All rights reserved.