Sun logo      Previous      Contents      Next     

Sun Java™ System Application Server Platform Edition 8 Administration Guide

Chapter 1
Getting Started

This chapter briefly describes the Sun Java™ System Application Server Platform Edition 8 and introduces basic administration tasks. This chapter contains following sections:


About the Sun Java™ System Application Server Platform Edition 8

What is the Sun Java™ System Application Server Platform Edition 8?

The Sun Java™ System Application Server Platform Edition 8 provides a robust J2EE platform for the development, deployment, and management of enterprise applications. Key features include transaction management, performance, scalability, security, and integration. The Application Server supports services from Web publishing to enterprise-scale transaction processing, while enabling developers to build applications based on JavaServer Pages (JSP™), Java servlets, and Enterprise JavaBeans™ (EJB™) technology.

The Sun Java™ System Application Server Platform Edition 8 is FREE for development, production deployment, and redistribution. For more information on redistribution, please visit:

http://www.sun.com/software/products/appsrvr/appsrvr_oem.html

Application Server Architecture

This section describes Figure 1-1, which shows the high-level architecture of the Application Server.

Containers

A container is a runtime environment that provides services such as security and transaction management to J2EE components. Figure 1-1 shows the two types of J2EE containers: Web and EJB. Web components, such as JSP pages and servlets, run within the Web container. Enterprise beans, the components of EJB technology, run within the EJB container.

Client Access

At runtime, browser clients access Web applications by communicating with the Web server via HTTP, the protocol used throughout the internet. The HTTPS protocol is for applications that require secure communication. Enterprise bean clients communicate with the Object Request Broker (ORB) through the the IIOP or IIOP/SSL (secure) protocols. The Application Server has separate listeners for the HTTP, HTTPS, IIOP, and IIOP/SSL protocols. Each listener has exclusive use to a specific port number.

Web Services

On the J2EE 1.4 platform, you can deploy a Web application that provides a Web service implemented by Java API for XML-Based RPC (JAX-RPC). A J2EE application or component can also be a client to other Web services. Applications can access XML registries through the Java API for XML Registries (JAXR).

Services for Applications

The J2EE platform was designed so that the containers provide services for applications. Figure 1-1 shows the following services:

Access to External Systems

The J2EE platform enables applications to access systems that are outside of the application server. Applications connect to these systems through objects called resources. As an administrator, one of your responsibilities will be resource configuration. The J2EE platform enables access to external systems through the following APIs and componenets:

Server Administration

The lower right-hand corner of Figure 1-1 shows some of the tasks performed by the administrator of the Application Server. For example, as an administrator, you will deploy (install) applications and monitor the server’s performance. You will perform these tasks with the administration tools provided by the Application Server. See the section Tools for Administration.

application server architecture

Figure 1-1  Sun Java™ System Application Server Platform Edition 8 Architecture

Administrative Domains

Administrative domains provide a basic security structure whereby different administrators can administer specific groups (domains) of application server instances. By grouping the server instances into separate domains, different organizations and administrators can share a single Application Server installation. Each domain has its own configuration, log files, and application deployment areas that are independent of other domains. If you change the configuration for one domain, the configurations of other domains are not affected.

In an Admin Console session, you can configure and manage a single domain. Each domain has its own administration server, which has a unique port number. You specify the port number in the URL of your browser to run the Admin Console.

In this release, each administrative domain has a single application server instance. An application server instance may belong to just one domain. When you installed the Application Server, an administrative domain named domain1 was automatically created.

Tools for Administration

The Application Server includes two administrative tools:

Admin Console

The Admin Console is a browser-based tool that features an easy-to-navigate interface and online help. This manual provides step-by-step instructions for using the Admin Console. The administration server must be running in order for you to use the Admin Console.

When you installed the Application Server, you chose a port number for the server, or used the default port of 4848. You also specified a user name and password.

To start the Admin Console, in a web browser type:

http://hostname:port

For example:

http://austen.sun.com:4848

If you are running the Admin Console on the machine on which the Application Server was installed, you can specify localhost for the host name.

On Windows, you can start the Admin Console from the Start menu by choosing Programs -> Sun Microsystems -> J2EE 1.4 SDK -> Admin Console.

The installation program creates the default administrative domain (named domain1) with the default port number 4848. After installation, you may choose to create additional administrative domains. Each domain has its own administration server, which has a unique port number. When you specify the URL for the Admin Console, be sure to use the port number for the domain that you want to administer.

The asadmin Utility

The asadmin utility is a command-line tool. You can use the asadmin utility and the commands associated with it to perform the same set of tasks as you can perform in the Admin Console. For example, you can start and stop domains, configure the server, and deploy applications.

You can use these commands either from a command prompt in the shell, or you can call them from other scripts and programs. You can use these commands to automate repetitive administration tasks.

To start the asadmin utility:

$ asadmin

To list the commands available within asadmin:

asadmin> help

You can also issue an asadmin command at the shell’s command prompt:

$ asadmin help

To view a command’s syntax and examples, type help followed by the command name. For example:

asadmin> help create-jdbc-resource

The asadmin help information for a given command displays the Unix man page of the command. These man pages are also available in HTML format.

Configuration Changes and Restarting the Server

If you make the following configuration changes, you must restart the server for the changes to take effect:

For instructions, see Restarting the Server.

With dynanamic configuration, most changes will take effect while the server is running. If you make the following configuration changes, you do NOT have to restart the server:

Note that the asadmin reconfig command has been deprecated and is no longer necessary. Configuration changes are applied to the server dynamically.

Changing Port Numbers

This section describes the ports used by the Application Server and explains how to change port numbers with the Admin Console. This section contains the following topics:

Ports in the Application Server

Table 1-1 describes the the port listeners of the Application Server.

Table 1-1  Application Server Listeners that Use Ports

Listener

Description

Administrative server

A domain’s administrative server is accessed by the Admin Console and the asadmin utility. For the Admin Console, you specify the port number in the URL of the browser. If you execute an asadmin command remotely, you must specify the port number with the --port option.

HTTP

The Web server listens for HTTP requests on a port. To access deployed Web applications and services, clients connect to this port.

HTTPS

Web applications configured for secure communications listen on a separate port.

IIOP

Remote clients of enterprise beans (EJB components) access the beans through the IIOP listener.

IIOP, SSL

Another port is used by the IIOP listener configured for secure communications.

IIOP, SSL and
mutual authentication

Another port is used by the IIOP listener configured for mutual (client and server) authentication.

Viewing Port Numbers

  1. In the tree component, select the Application Server node.
  2. Select the General tab.
  3. On the General Information page, note the port numbers.

Changing the Administrative Server Port

  1. In the tree component, expand the HTTP Service node.
  2. Select the HTTP Listeners node.
  3. On the HTTP Listeners page, in the Name column select the admin-listener entry.
  4. On the Edit HTTP Listener page, change the value of the Listener Port field.
  5. Restart the server.

Changing an HTTP Port

  1. In the tree component, expand the HTTP Service node.
  2. Select the HTTP Listeners node.
  3. On the HTTP Listeners page, in the Name column select the the listener whose port number you want to change.
  4. On the Edit HTTP Listener page, change the value of the Listener Port field.
  5. Click Save.
  6. Restart the server.

Changing an IIOP Port

  1. In the tree component, expand the ORB node.
  2. Select the IIOP Listeners node.
  3. On the IIOP Listeners page, in the Name column select the the listener whose port number you want to change.
  4. On the Edit IIOP Listener page, change the value of the Listener Port field.
  5. Click Save.
  6. Restart the server.

Changing the J2SE Software Used By the Application Server

The Application Server relies on the Java 2 Standard Edition (J2SE) software. When you installed the Application Server, you specified the directory of the J2SE software. For instructions on changing the J2SE software, see Configuring the JVM General Settings.

Further Information


Configuring Domains

Creating a Domain

Domains are created using the create-domain command. The following example command creates a domain named mydomain. The administration server listens on port 123 and the admininstrative user name is buzz. The command prompts for the administrative password.

$ asadmin create-domain --adminport 123 --adminuser buzz mydomain

To start the Admin Console for this domain, in a browser you would enter the following URL:

http://hostname:123/asadmin

For the preceding create-domain example, the domain’s log files, configuration files, and deployed applications will reside in the following directory:

install_dir/domains/mydomain

To create the domain’s directory in another location, you specify the --domaindir option. For the full synax of the command, type asadmin help create-domain.

Deleting a Domain

Domains are deleted using the asadmin delete-domain command. Only the operating system user (or root) who can administer the domain can execute this command successfully. To delete a domain named mydomain, for example, type the following command:

$ asadmin delete-domain mydomain

Listing Domains

The domains created on a machine can be found using the asadmin list-domains command. To list the domains in the default install_dir/domains directory, type this command:

$ asadmin list-domains

To list domains that were created in other directories, specify the --domaindir option.


Starting and Stopping a Domain

Starting a Domain

When you start a domain, you start its administration server and application server instance. Once the application server instance is started it runs constantly, listening for and accepting requests. Each domain must be started separately. To start a domain, use one of the following methods.

Starting With the asadmin start-domain Command

To start a domain, you type the asadmin start-domain command and specify the domain name. For example, to start the default domain (domain1), you type the following:

$ asadmin start-domain domain1

If there is only one domain, you may omit the domain name. For the full command syntax, type asadmin help start-domain.

Starting With the Windows Start Menu

On Windows, you can start the default domain from the Windows Start menu by choosing Programs -> Sun Microsystems -> J2EE 1.4 SDK -> Start Default Server.

Restarting the Server

In this release, restarting the server is the same as restarting the domain. To restart the domain, you stop and start the domain.

Stopping a Domain

Stopping a domain shuts down its administration server and application server instance. When you stop a domain, the server instance stops accepting new connections and then waits for all outstanding connections to complete. It may take a few seconds for the server instance to complete its shut-down process. While the domain is stopped, you cannot use the Admin Console or most asadmin commands.

Stopping With the asadmin stop-domain Command

To stop a domain, you type the asadmin stop-domain command and specify the domain name. For example, to stop the default domain (domain1), you type the following:

$ asadmin stop-domain domain1

If there is only one domain, then the domain name is optional. For the full syntax, type asadmin help stop-domain.

Stopping With the Admin Console

  1. In the tree component, select the Application Server node.
  2. Select the General tab.
  3. On the General Information page, click Stop Server.

Stopping With the Windows Start Menu

On Windows, you can stop the default domain from the Start menu by choosing Programs -> Sun Microsystems -> J2EE 1.4 SDK -> Stop Default Server.



Previous      Contents      Next     


Copyright 2004 Sun Microsystems, Inc. All rights reserved.