Administration Console Online Help
|
Creating Domains and Servers
A domain is a collection of WebLogic Server resources such as servers, clusters, database connections, and security services. A server is a single instantiation of the WebLogic Server software, and it gives your applications access to resources such as database connections, security and messaging services, EJBs, and other applications. In addition, a server provides clients access to your applications.
The following sections describe creating domains and servers:
For more information about domains and servers, refer to "Overview of WebLogic Server Domains."
Overview of Creating Domains and Servers
Use the Domain Configuration Wizard to create domains and servers. You can create multiple domains to support different environments or business requirements:
If you want to add a Managed Server to an existing domain, use the Administration Console as described in Adding Managed Servers to an Existing Domain.
Creating Domains, Administration Servers, and Managed Servers
The following sections provide instructions for using the Domain Configuration Wizard to create a domain with servers:
Starting the Domain Configuration Wizard
The WebLogic Server installation program provides the option to automatically start the Domain Configuration Wizard when you select the Custom Install option during the installation. You can also start the Domain Configuration Wizard at any time after installing WebLogic Server using either a GUI or a console (command-line) interface, as described below.
Starting in GUI Mode
Running the Configuration Wizard in GUI mode executes the Configuration Wizard program in a graphics environment that can run on Windows and some Unix systems. If you try to start the Configuration Wizard in GUI-mode on a system that cannot support the graphical display, the Configuration Wizard automatically starts in console mode.
To start the Configuration Wizard in GUI mode on a Windows platform, select the Run Configuration Wizard option from the BEA program group in the Windows Start Menu:
Start—>Programs—>BEA—>WebLogic Platform 8.1—>Domain Configuration Wizard
To start the Domain Configuration Wizard in GUI mode on a UNIX platform (or from a Windows command prompt):
- Log in to the target Windows or UNIX system.
- Open a command-line shell.
- Go to the following directory \common\bin subdirectory of the WebLogic Server installation directory. For example:
cd c:\bea\weblogic810\common\bin
- Invoke the dmwiz.cmd or dmwiz.sh script to start the Configuration Wizard:
dmwiz.cmd
Starting in Console Mode
Running the Configuration Wizard in Console mode executes the Configuration Wizard program in a text-based environment. To start the Configuration Wizard in Console mode:
- Log in to the target Windows or UNIX system.
- Open a command-line shell.
- Go to the following directory \common\bin subdirectory of the WebLogic Server installation directory. For example:
cd c:\bea\weblogic810\common\bin
- Invoke the dmwiz.cmd or dmwiz.sh script with the -mode=console argument:
dmwi
Create a Domain with a Single Server Instance
This type of domain configuration is recommended for development or testing, not for a production environment. To create a new domain with a single WebLogic Server instance that acts as both the Administration Server and application host server:
- Start the Domain Configuration Wizard using the instructions in Starting the Domain Configuration Wizard. The instructions that follow assume that you are running the Domain Configuration Wizard in GUI mode.
The Domain Configuration Wizard displays the Choose Domain Type and Name screen.
- Perform the following actions:
- Select a Template: Select WLS Domain, WLS Examples, or WLS Petstore. See Understanding Domain Configuration Wizard Templates for more information.
- Name: Enter a domain name using alphanumeric characters. This field will not accept spaces. The Domain Configuration Wizard uses the name you enter to create a domain subdirectory for the new domain.
- Click the Next button to continue to the Choose Server Type screen.
- Select the Single Server (Standalone Server) option and click Next. The Domain Configuration Wizard displays the Choose Domain Location screen.
- Enter a top-level directory to store your custom domain, or use the Browse button to select a directory. Click Next to move to the Configure Single Server screen.
- Fill in the fields of the Configure Single Server screen as follows:
- Server Name—Enter a server name using alphanumeric characters. This field will not accept spaces.
Each server within a domain must have a unique name.
The server name is not used as part of the URL for applications that are deployed on the server. It is for your identification purposes only. The server name displays in the Administration Console, and if you use WebLogic Server command-line utilities or APIs, you use this name to identify the server.
- Listen Address—Leave this field empty to accept the default behavior, or enter an IP address of the computer that hosts the server, a DNS name that resolves to the host, or localhost. For more information, refer to Setting the Listen Address.
Servers can be reached through the following URL: protocol://listen-address:listen-port
- Listen Port—Enter a numeric value for the listen port. The range is 1 to 65535. The default port is 7001.
For more information, refer to Setting the Listen Ports.
- Server SSL Listen Port: Enter a numeric value for the SSL listen port. The default port is 7002.
By default, the server instance uses demonstration certificates for SSL communication. In a production environment, you must configure the server to use certificates from a certificate authority.
For more information, refer to Setting the Listen Ports.
- Click Next to move to the Create System User and Password screen.
- Enter the user name and password required to boot and connect to the server you configured. Click Next.
- For Windows systems, the Domain Configuration Wizard prompts you to install the Administration Server as a Windows service. Select Yes if you want to run the server as a Windows service, or No to start the server from the command-line or windows Start menu. Click Next to continue.
- For Windows systems, the Domain Configuration Wizard prompts you to install the domain in the Windows Start menu. Select Yes if you want to install the server start script under the Start menu. Click Next to move to the Configuration Summary screen.
- Verify the new domain and server configuration in the Configuration Summary screen. If you want to edit your selections, click the back button to return to the correct screen. Otherwise, click Create to create the new domain with the standalone server you specified.
After you create a domain refer to Configuring Serversfor information on configuring attributes that the Domain Wizard does not configure.
Create a Domain with Administration Server and Managed Servers
This type of domain configuration is recommended for production environments because it provides an Administration Server to manage the domain and Managed Servers to host applications. To create a new domain with one or more Managed Servers and an Administration Server:
- Start the Domain Configuration Wizard using the instructions in Starting the Domain Configuration Wizard. The instructions that follow assume that you are running the Domain Configuration Wizard in GUI mode.
The Domain Configuration Wizard displays the Choose Domain Type and Name screen.
- Perform the following actions:
- Select a Template: Select WLS Domain, WLS Examples, or WLS Petstore. See Understanding Domain Configuration Wizard Templates for more information.
- Name: Enter a domain name using alphanumeric characters. This field will not accept spaces. The Domain Configuration Wizard uses the name you enter to create a domain subdirectory for the new domain.
- Click the Next button to continue to the Choose Server Type screen.
- Select the Admin Server with Managed Server(s) option and click Next. The Domain Configuration Wizard displays the Choose Domain Location screen.
- Enter a top-level directory to store your custom domain, or use the Browse button to select a directory. Click Next to move to the Configure Managed Servers in Admin Server screen.
- To add a new Managed Server to the domain, click Add and fill in the fields of the Add Server dialog box as follows:
- Server Name—Enter a server name using alphanumeric characters. This field will not accept spaces.
Each server within a domain must have a unique name.
The server name is not used as part of the URL for applications that are deployed on the server. It is for your identification purposes only. The server name displays in the Administration Console, and if you use WebLogic Server command-line utilities or APIs, you use this name to identify the server.
- Listen Address—Enter an IP address of the computer that hosts the server, a DNS name that resolves to the host, or localhost.
Servers can be reached through the following URL: protocol://listen-address:listen-port
For more information, refer to Setting the Listen Address.
- Listen Port—Enter a numeric value for the listen port. The range is 1 to 65535.
For more information, refer to Setting the Listen Ports.
- Server SSL Listen Port: Enter a numeric value for the SSL listen port.
By default, the server instance uses demonstration certificates for SSL communication. In a production environment, you must configure the server to use certificates from a certificate authority.
For more information, refer to Setting the Listen Ports.
- Click Add on the Add Server dialog box to add the new Managed Server and return to the Configure Managed Servers in Admin Server screen.
Note: If you make a mistake and want to edit or delete a server you added, select the server name and click the Edit or Delete button.
- Repeat step 6 to add additional Managed Servers, or click Next to move to the Configure Admin Server screen.
- Fill in the fields of the Configure Admin Server screen as follows:
- Server Name: Enter a server name using alphanumeric characters. This field will not accept spaces.
For more information, refer to step 6.
- Listen Address—Leave this field empty to accept the default behavior, or enter an IP address of the computer that hosts the server, or a DNS name that resolves to the host. Enter localhost only if all Managed Servers are on the same computer as the Administration Server. For more information, refer to Setting the Listen Address.
Servers can be reached through the following URL: protocol://listen-address:listen-port
- Server Listen Port: Enter a numeric value for the listen port. The range is 1 to 65535. The default port is 7001.
- Server SSL Listen Port: Enter a numeric value for SSL listen port. The range is 1 to 65535. The default port is 7002.
- Click Next to move to the Create System User and Password screen.
- Enter the user name and password required to boot and connect to the Administration Server you configured. Click Next.
- For Windows systems, the Domain Configuration Wizard prompts you to install the Administration Server as a Windows service. Select Yes if you want to run the server as a Windows service, or No to start the server from the command-line or windows Start menu. Click Next to continue.
- For Windows systems, the Domain Configuration Wizard prompts you to install the domain in the Windows Start menu. Select Yes if you want to install the server start scripts under the start menu. Click Next to move to the Configuration Summary screen.
- Verify the new domain and server configuration in the Configuration Summary screen. If you want to edit your selections, click the back button to return to the correct screen. Otherwise, click Create to create the new domain with the servers you specified.
After you create a domain refer to Configuring Servers for information on configuring attributes that the Domain Wizard does not configure.
Create a Domain with Administration Server and Clustered Managed Servers
This type of domain configuration is recommend for production environments that require the improved availability and performance provided by failover and load balancing in a WebLogic Server cluster. For guidelines on supplying addressing information for a cluster and its members, see "Identify Names and Addresses" in Using WebLogic Server Clusters.
To create a new domain with a cluster of Managed Servers and a standalone Administration Server:
- Start the Domain Configuration Wizard using the instructions in Starting the Domain Configuration Wizard. The instructions that follow assume that you are running the Domain Configuration Wizard in GUI mode.
The Domain Configuration Wizard displays the Choose Domain Type and Name screen.
- Perform the following actions:
- Select a Template: Select WLS Domain, WLS Examples, or WLS Petstore. See Understanding Domain Configuration Wizard Templates for more information.
- Name: Enter a domain name using alphanumeric characters. This field will not accept spaces. The Domain Configuration Wizard uses the name you enter to create a domain subdirectory for the new domain.
- Click the Next button to continue to the Choose Server Type screen.
- Select the Admin Server with Clustered Managed Server(s) option and click Next. The Domain Configuration Wizard displays the Choose Domain Location screen.
- Enter a top-level directory to store your custom domain, or use the Browse button to select a directory. Click Next to move to the Configure Clustered Servers screen.
- To add a new Managed Server to the domain, click Add and fill in the fields of the Add Server dialog box as follows:
- Server Name—Enter a server name using alphanumeric characters. This field will not accept spaces.
Each server within a domain must have a unique name.
The server name is not used as part of the URL for applications that are deployed on the server. It is for your identification purposes only. The server name displays in the Administration Console, and if you use WebLogic Server command-line utilities or APIs, you use this name to identify the server.
- Listen Address—Leave this field empty to accept the default behavior, or enter an IP address of the computer that hosts the server, a DNS name that resolves to the host, or localhost. For more information, refer to Setting the Listen Address.
Servers can be reached through the following URL: protocol://listen-address:listen-port
- Listen Port—Enter a numeric value for the listen port. The range is 1 to 65535.
For more information, refer to Setting the Listen Ports.
- Server SSL Listen Port: Enter a numeric value for the SSL listen port.
By default, the server instance uses demonstration certificates for SSL communication. In a production environment, you must configure the server to use certificates from a certificate authority.
For more information, refer to Setting the Listen Ports.
- Click Add on the Add Server dialog box to add the new Managed Server and return to the Configure Managed Servers in Admin Server screen.
Note: If you make a mistake and want to edit or delete a server you added, select the server name and click the Edit or Delete button.
- Repeat step 6 to add additional Managed Servers, or click Next to move to the Configure Cluster screen.
- Enter the following information in the Configure Cluster screen:
- Cluster Name: Enter a cluster name using alphanumeric characters. This field will not accept spaces. The default is mycluster.
- Cluster MultiCast Address: Enter a multicast address for the cluster. This address must begin with 237.xx.xx.xxxx, 238.xx.xx.xxxx, or 239.xx.xx.xxxx.
- Cluster MultiCast Port: Enter a numeric value for the multicast port. The range of values is up to 65535.
- Cluster Address: Enter the cluster address. For production use, enter a DNS name that maps to the individual IP addresses of the Managed Servers in the cluster. For testing or development purposes, use a comma-separated list of the IP addresses and ports assigned to the Managed Servers (this is the default entry).
The cluster address forms the host name portion of URLs for requests directed to the cluster. If the cluster address is not set, EJB handles may not work properly. For more information, see "Cluster Address" in Using WebLogic Server Clusters.
- Click Next to move to the Configure Admin Server (with Cluster) screen.
- Fill in the fields of the Configure Admin Server (with Cluster) screen as follows:
- Server Name: Enter a server name using alphanumeric characters. This field will not accept spaces.
For more information, refer to step 6.
- Listen Address—Leave this field empty to accept the default behavior, or enter an IP address of the computer that hosts the server, or a DNS name that resolves to the host. Enter localhost only if all Managed Servers are on the same computer as the Administration Server. For more information, refer to Setting the Listen Address.
Servers can be reached through the following URL: protocol://listen-address:listen-port
- Server Listen Port: Enter a numeric value for the listen port. The range is 1 to 65535. The default port is 7001.
For more information, refer to step 6.
- Server SSL Listen Port: Enter a numeric value for SSL listen port. The range is 1 to 65535. The default port is 7002.
For more information, refer to step 6.
- Click Next to move to the Create System User and Password screen.
- Enter the user name and password required to boot and connect to the Administration Server you configured. Click Next.
- For Windows systems, the Domain Configuration Wizard prompts you to install the Administration Server as a Windows service. Select Yes if you want to run the server as a Windows service, or No to start the server from the command-line or windows Start menu. Click Next to continue.
- For Windows systems, the Domain Configuration Wizard prompts you to install the domain in the Windows Start menu. Select Yes if you want to install the server start scripts under the start menu. Click Next to move to the Configuration Summary screen.
- Verify the new domain and server configuration in the Configuration Summary screen. If you want to edit your selections, click the back button to return to the correct screen. Otherwise, click Create to create the new domain with the servers you specified.
After you create a domain refer to Configuring Servers for information on configuring attributes that the Domain Wizard does not configure.
What Does the Domain Configuration Wizard Create?
Based on the responses you provide to the dialogs presented by the Domain Configuration Wizard, the wizard creates a config.xml file for the domain. The Domain Configuration Wizard also creates startup scripts for the server instances in the domain, and other helper files and directories to help you start and use the new domain and its servers.
The Domain Configuration Wizard stores the config.xml file and all other generated components in a domain directory that you specify during the dialogs (by default /user_projects/mydomain).
The following table describes the files and directories that the Domain Configuration Wizard creates.
Table 2-1 Components Installed with Domain Configuration Wizard
Component
|
Function
|
config.xml
|
config.xml file is an XML document that describes the configuration of a WebLogic Server domain.
To learn more about config.xml, see BEA WebLogic Server Configuration Reference
|
/applications
|
Stores the default Web Application for servers in the domain. If you select a template that includes WebLogic Server examples, then this directory also stores JAR and EAR files for individual examples.
Note that if you select a template that installs WebLogic Server examples or the Petstore application, the examplesWebApp and petstore application files remain in the \samples\server\stage subdirectory of the WebLogic Server installation directory.
|
/logs
|
Stores log files for servers in the domain.
|
setEnv.cmd, setEnv.sh
|
Set environment variables for the domain.
|
setExamplesEnv.cmd, setExamplesEnv.sh
|
Set environment variables for domains that include the WebLogic Server example applications.
|
startWebLogic.cmd, startWebLogic.sh
|
Start the Administration Server for a custom domain.
|
startManagedWebLogic.cmd, startManagedWebLogic.sh
|
Start a Managed Server in a custom domain.
|
startExamplesServer.cmd, startExamplesServer.sh
|
Start a server that hosts the WebLogic Server example applications.
|
startPetStore.cmd, startPetStore.sh
|
Start a server that hosts the Pet Store example applications.
|
demokey.pem, democert.pem
|
Provide sample SSL protocol support for servers in the domain.
|
Windows Start Menu Items
|
Provide Start menu support for starting domain servers in a Windows environment.
|
Understanding Domain Configuration Wizard Templates
The templates available in the Domain Configuration Wizard vary, based on which WebLogic Platform components are installed in your environment. This section describes the templates typically available in a WebLogic Server installation. If you have other WebLogic Platform components installed, other templates may be available in the Domain Configuration Wizard. For information about other templates, see Configuration Wizard Template Reference.
The Domain Configuration Wizard templates for WebLogic Server installations are organized into three main categories:
- WLS Domain— These templates create a new domain without installing any applications.
- WLS Examples—These templates create a new domain in which one Managed Server is configured to run the WebLogic Server example applications. This server is similar to the examplesServer created when you choose the Typical Install option in the WebLogic Server installation program.
- WLS Petstore—These templates create a new domain in which one Managed Server is pre-configured to run the Pet Store sample application. This server is similar to the petstoreServer created with a typical WebLogic Server installation.
Adding Managed Servers to an Existing Domain
After you create a domain, you might decide to add one or more Managed Servers. Usually, you create Managed Servers to run your business applications in a production environment. While the Managed Server can run on any computer on which WebLogic Server is installed, the configuration for the Managed Server resides within the domain's config.xml file.
This section describes the following tasks:
Creating a Managed Server in an Existing Domain
To create a Managed Server in the currently active domain, do the following:
- In the left pane of the Administration Console, click on the name of the Servers folder.
The Administration Console displays the Servers page in the right pane. It provides a list of servers that have already been defined in the domain.
- On the Servers page, click Configure a new Server.
The Administration Console displays the Servers > Create page in the right pane.
- On the Servers > Create page, in the Configuration > General tab, enter the name of the server in the Name field.
Each server within a domain must have a unique name.
The server name is not used as part of the URL for applications that are deployed on the server. It is for your identification purposes only. The server name displays in the Administration Console, and if you use WebLogic Server command-line utilities or APIs, you use this name to identify the server.
- Click Create.
The new server appears under the Servers node in the left pane. The Administration Console updates the domain's config.xml file with the new server configuration data.
For information about configuring the server, refer to Configuring Servers.
Cloning a Server
Cloning a server creates a new server instance with the same attributes as the original. server.
- Click the Servers node in the left pane.
The Administration Console displays the Servers page in the right pane. It provides a list of servers that have already been defined in the domain.
- On the Servers page, click the Clone icon in the row of the server you want to clone.
A dialog displays in the right pane showing the tabs associated with cloning a new server.
- Enter a new name for the server.
- Click the Clone button in the lower right corner to create a server instance with the name you specified in the Name field.
The new server appears under the Servers node in the left pane. The Administration Console updates the domain's config.xml file with the new server configuration data.
For information about configuring the server, refer to Configuring Servers.