2 Creating a WebLogic Domain

You can create a new WebLogic domain by using the Configuration Wizard in graphical mode. Depending on your domain requirements and customizations, the Configuration Wizard takes you through a series of screens during the domain creation process.

This chapter includes the following sections:

Setting the CONFIG_JVM_ARGS Environment Variable

Before you start the Configuration Wizard, set a value for the CONFIG_JVM_ARGS environment variable. Setting the appropriate value for the variable enables you to specify the type of domain you want to create, whether expanded or compact.

Set the value to -Djava.security.egd=file:/dev/./urandom to reduce the time the Configuration Wizard takes to create or update a domain.

In addition, if you want to create a compact domain on either Windows or Linux, include the following value for the CONFIG_JVM_ARGS environment variable: -Dcom.oracle.cie.config.showProfile=true

This setting causes domain profile selections (compact and expanded) to appear on the Configuration Type screen of the Configuration Wizard. For more information about domain profiles, see Domain Topology Profiles in Domain Template Reference.

Domain Creation Process

You can use the Configuration Wizard to create a WebLogic domain, by selecting either the product components to include in your domain or by selecting the template JAR files. If necessary, you can also customize the domain to suit your environment.

Table 2-1 shows the sequence of the Configuration Wizard screens. The screens that you see depend on your domain requirements and whether you need to customize your domain.

You may want to customize your domain in the following circumstances:

  • To create a multi-server or clustered domain when using the default settings. All the predefined WebLogic Server templates (those delivered with WebLogic Server) create single-server domains.

  • To use a database that is different from the default database in the domain or extension template. In this case, you must customize the JDBC settings to point to the appropriate database.

  • To customize the listen port and the SSL port.

  • To create a test environment by using a domain template that you received, and to modify the domain configuration to work in the test environment based on your requirements.

Domain Version Restrictions

When you create a domain by using a custom template, either by using WLST or the Create Domain Using Custom Template option on the Templates screen of the Configuration Wizard, you have to keep a few restrictions in mind.

The restrictions include the following:

  • The versions of the WebLogic Server templates that were used to create the custom domain and custom domain template must be the same version as the WebLogic Server installation in which the domain is used. For example, if you created a WebLogic domain by using the WebLogic Server Base Domain 10.3.6 template, and then created a custom domain template from that domain, you cannot use the custom domain template to create a domain in a WebLogic Server 12.2.1 installation.

  • If you want to create a custom domain template that was created from a domain from a previous version of WebLogic Server, you must first upgrade that domain to the WebLogic Server version in which you want to use the domain. You can upgrade the domain by using either WLST or the Fusion Middleware Reconfiguration Wizard. For more information about the Reconfiguration Wizard screen, click Help on the relevant screen.

For more information about domain version restrictions, see Domain Restrictions in Understanding Domain Configuration for Oracle WebLogic Server.

Starting the Configuration Wizard

You can start the Configuration Wizard in graphical mode either from the Windows Start menu or from the command line. The console for the machine on which the product installation resides must support Java-based GUIs.

  • To start the Configuration Wizard in graphical mode on a Windows platform, choose Start > All Programs > Oracle > Oracle Home > WebLogic Server version > Tools > Configuration Wizard.

  • To start the Configuration Wizard in graphical mode from a Windows command prompt or on UNIX systems:

    1. Log in to the system on which the product is installed.

    2. Open an MS-DOS command prompt window (on Windows) or a command shell (on UNIX).

    3. Go to the following directory:

      On Windows: ORACLE_HOME/oracle_common/common/bin

      On UNIX: ORACLE_HOME/oracle_common/common/bin

      Replace ORACLE_HOME with the Oracle Home directory that was specified during installation.

    4. Execute the following command:

      On Windows: config.cmd

      On UNIX: sh config.sh

      Note:

      When you run the config.cmd or config.sh command, the following error message appears if the default cache directory is not valid:

      *sys-package-mgr*: can't create package cache dir

      You can change the cache directory by including the -Dpython.cachedir=valid_directory option in the command line.

      To create a log file of the Configuration Wizard session, include the -log=config.log -log_priority=debug parameter in the command. You can specify any file name for the log file, such as config_today.log. The log file is stored in the logs directory of the Oracle Home directory. Other valid values for log_priority are OFF, SEVERE, WARNING, INFO, CONFIG, FINE, FINER, FINEST, and ALL.

      The Configuration Type screen appears.

Creating a WebLogic Domain in Graphical Mode

The Configuration Wizard takes you through a series of screens that help you create a WebLogic Server domain. Additional screens appear depending on the components that you add for the domain, and on other factors.

To create a new WebLogic Domain, start the Configuration Wizard as described in Starting the Configuration Wizard.

Note:

In situations where you cannot run the Configuration Wizard in the GUI mode, Oracle recommends that you use a WLST script to create or extend a domain. See Creating and Using a Domain Template (Offline) in Understanding the WebLogic Scripting Tool.

If your installation includes Fusion Middleware products, see Configuring Fusion Middleware Domains, for instructions. Fusion Middleware product configuration includes additional Configuration Wizard screens that are not included in the workflow in this chapter.

The Configuration Wizard displays a sequence of screens, in the order listed in Table 2-1. For more information on each screen, refer to the related section in Configuration Wizard Screens, or click the link in the Screen column.

Table 2-1 Configuration Screens for Creating a New WebLogic Domain

Screen When Does This Screen Appear? Perform the Following Action

Configuration Type - No Profiles

When CONFIG_JVM_ARGS is not set to display domain profile options

Select Create a new domain.

In the Domain Location box, enter the path to the new domain, or click Browse to create the domain directory.

Click Next.

Configuration Type - Profiles

When CONFIG_JVM_ARGS is set to -Dcom.oracle.cie.config.showProfile=true

Select Create a new expanded domain or Create a new compact domain as appropriate.

In the Domain Location box, enter the path to the new domain, or click Browse to create the domain directory.

Click Next.

Templates

Always

Select the appropriate option:

  • Select Create Domain Using Product Templates, and then select the check box for each product to include in the domain.

  • Select Create Domain Using Custom Template, and then click Browse to locate the domain template on your local drive or network.

Click Next.

High Availability Options

Only if the templates that you have selected in the Templates screen are configured for high availability.

You can configure the following HA options:
  • Select Enable Automatic Service Migration to automatically migrate services from an unhealthy hosting server to a healthy active server. You can choose high-availability database leasing or non-database consensus leasing for migration.

    See Leasing and Service Migration in Administering Clusters for Oracle WebLogic Server.

  • Select the persistence type for Java Transaction API (JTA). You can choose to persist transaction logs (Tlogs) in a database or in a file-based store.

    See Using the Default Persistent Store in Administering Server Environments for Oracle WebLogic Server

  • Select the persistence type for JMS servers. You can use either a file store or a JDBC store.

    See JMS and JTA High Availability in High Availability Guide.

Click Next.

Application Location

Only if one or more of the selected templates define an application

Specify the directory in which the domain applications are to be stored.

Click Next.

Administrator Account

Always

Specify the username and password for the administrator account of the domain.

Click Next.

Domain Mode and JDK

Always

Select the startup mode to use: Development or Production.

Select the JDK to use in the domain or click Browse to navigate to the JDK you want to use.

Click Next.

Database Configuration Type

Only if the domain includes components that require JDBC data sources, GridLink data sources, or Oracle RAC multi-data sources

See Configuring Data Sources, for information about the relevant screens.

Database Scripts

Only if the selected products or template includes a set of SQL files organized by database type

Select the data sources for which you want to run the database scripts.

Select the database version.

Click Run Scripts.

After you run the necessary scripts, click Next.

Advanced Configuration

Always

Select the check box for each category (if any) for which you want to perform advanced configuration tasks.

The available check boxes depend on the resources that are configured in the selected products or template.

Click Next.

See Advanced Configuration, for the sequence of screens that appear if you select all available options.

Configuration Summary

Always

Review the configuration for your domain by selecting a Summary View, and then selecting individual items in the list for that view.

If the domain is configured as you want it, click Create to create the domain.

To modify the configuration, click Previous to return to the appropriate screen for the settings you want to change.

Configuration Progress

Always

Shows the progress of the domain creation.

When the process completes, click Next.

Configuration Success

Always

Review the domain creation results.

Click Finish to exit the Configuration Wizard.

Configuring Data Sources

The data source configuration screens appear in the Configuration Wizard only if the domain includes components that require JDBC data sources or Oracle RAC multi-data sources.

Table 2-2 lists the sequence of data source screens that are displayed in the Configuration Wizard. For more information on each screen, refer to the related section in Configuration Wizard Screens, or click the link in the Screen column.

After you configure the screens described in this section, return to Table 2-1.

Table 2-2 Data Source Configuration Screens

Screen When Does This Screen Appear? Perform the Following Action

JDBC Data Sources

Only if the domain includes components that require JDBC data sources

Select a data source to configure, and then do one of the following:

  • Configure the fields for the data source.

  • Select the Convert to GridLink option.

  • Select the Convert to RAC multi-data source option.

Click Next to continue.

GridLink Oracle RAC Data Sources

Only if the domain includes components that require JDBC data sources, and you have selected the Convert to GridLink option for at least one data source on the Configure JDBC Data Source screen

Configure the fields for the Gridlink RAC data source, including the Service Name, Service Instance, ONS Host, wallet file, and wallet password.

Click Next to continue.

Oracle RAC Multi Data Sources

Only if the domain includes components that require JDBC data sources, and you selected the Convert to RAC multi-data source option for at least one data source on the Configure JDBC Data Source screen

Configure the fields for the Oracle RAC multi-data source, including the Oracle RAC host name, instance name, and port.

Click Next to continue.

JDBC Data Sources Test

Only if the domain includes components that require JDBC data sources

Select the data sources to test, and click Test Connection. Wait for one or more connection tests to complete.

Note: In order to test connections, the database to which you are trying to connect must be running.

If you do not want to test connections, deselect all data sources.

Click Next to continue.

Advanced Configuration

You can use the Advanced Configuration screen to select all categories for which you want to perform advanced configurations. For each category that you select, you can perform the advanced configurations in the appropriate configuration screen.

This section describes the sequence of screens that appear if you select the options listed on Advanced Configuration screen.

Table 2-3 Advanced Configuration Screens

Screen When Does This Screen Appear? Perform the Following Action

Administration Server

Only if you have selected Administration Server on the Advanced Configuration screen

Change the settings for the Administration Server as needed.

Click Next.

Node Manager

Only if you have selected Node Manager on the Advanced Configuration screen

Select the Node Manager Type.

Enter the username and password for accessing the Node Manager.

Click Next.

Managed Servers

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen

Add, delete, clone, or reconfigure Managed Servers as needed.

Click Next.

Clusters

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen

Add, delete, or reconfigure clusters as needed.

Click Next.

Server Templates

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen

Add templates to or delete templates from the domain that you are configuring.

Click Next.

Assign Servers to Clusters

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen, and your domain includes at least one cluster

Add servers to or remove servers from the clusters in your domain.

Click Next.

HTTP Proxy Applications

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen, and your domain includes at least one cluster, and at least one Managed Server that is not assigned to a cluster

For each cluster, specify whether or not you want to create an HTTP proxy application for the cluster. If you select the Create HTTP Proxy check box for a cluster, select the proxy server to use for that cluster.

Click Next.

Coherence Clusters

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen, and Coherence is installed with WebLogic Server

Accept the default cluster name or type a new name for the Coherence cluster.

Enter the port number to use as the Coherence cluster listen port.

Click Next.

Machines

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen

Select the Machine tab (Windows) or Unix Machine tab (UNIX).

Add machines as needed.

Configure the settings for each machine.

Click Next.

Assign Servers to Machines

Only if you have selected Managed Servers, Clusters, and Coherence on the Advanced Configuration screen, and there is at least one machine configured in the domain

Assign the Administration Server and Managed Servers to the appropriate machines.

Click Next.

Virtual Targets

Only if you have selected Topology on the Advanced Configuration screen.

Add, configure, and delete virtual targets that you want to use to run WebLogic Server in a multitenant mode.

For an overview of multitenancy in Oracle WebLogic Server, see Oracle WebLogic Server Multitenant in Using Oracle WebLogic Server Multitenant.

For a definition of virtual targets, see Virtual Targets in Using Oracle WebLogic Server Multitenant.

Click Next.

Partitions

Only if you have selected Topology on the Advanced Configuration screen.

Add the required number of partitions. Later, you assign virtual targets to each partition that you define.

For more information about virtual targets and partitions, see Configuring Virtual Targets: Overview and Configuring Domain Partitions: Overview in Using Oracle WebLogic Server Multitenant

Click Next.

Assign Virtual Targets to Partitions

Only if you have defined virtual targets and partitions for the domain being configured

Associate a virtual target to a partition. A partition can have zero or more virtual targets.

Click Next.

Deployments Targeting

Only if you have selected Deployments and Services on the Advanced Configuration screen, and a selected product or template contains J2EE applications or libraries

Select the target server or cluster on which you want to deploy applications or libraries.

Select the check box for each application or library that you want to deploy on the selected target.

Note:

While creating a Restricted JRF domain by using the config.cmd or config.sh command, you must target the Enterprise Manager (EM) related libraries to the cluster to access the Enterprise Manager Console.

Click Next.

Services Targeting

Only if you have selected Deployments and Services on the Advanced Configuration screen

Select the target server or cluster.

Select the check box for each service that you want to target.

Click Next.

File Stores

Only if you have selected File Store on the Advanced Configuration screen

Change the settings for each JMS file store as needed, and select the synchronous write policy for each file store.

Click Next.

Starting the Administration Server

You can start the Administration Server after you create the domain, by using either the WebLogic Server Administration Console or from the command line.

For more information about the various methods that you can use to start the Administration Server, see Starting and Stopping Servers in Administering Server Startup and Shutdown for Oracle WebLogic Server.

Running the Quick Start Configuration Wizard

The Quick Start Configuration Wizard helps you configure the sample domains and the Fusion Middleware product domains that use the Derby (JavaDB) database driver.

You can run the wizard automatically or manually depending on the domain type (sample or product) that you want to configure, as described below:

  • To configure the various sample domains, such as MedRec and the Examples Server, in your WebLogic Server installation, run the wizard by selecting the Automatically Launch Quick Start Configuration Wizard option on the Installation Complete screen of the WebLogic Server installer.

  • To configure Fusion Middleware product domains, run the wizard manually as described in this section. Schema JARs that are provided with the product is used to populate a domain_home/common/db directory.

Note:

The Quick Start Configuration Wizard supports only the Derby (JavaDB) database driver. If you are using another database, you cannot use the Quick Start Configuration Wizard to create your domain.

Before you run the Configuration Wizard manually in the Quick Start mode, you must set the CONFIG_JVM_ARGS environment variable to specify the full path and JAR file name for each template that you want to use for the domain. For the location and filename of templates provided by Oracle for WebLogic Server and other Fusion Middleware products, see the following resources in Domain Template Reference.

Windows

To set CONFIG_JVM_ARGS on a Windows system:

set CONFIG_JVM_ARGS="-DuserTemplates=template1,template2,template3, ..., templaten"

The following example uses the WebLogic Server base domain template and the Web Services JAX-WS template to create the domain:

set CONFIG_JVM_ARGS="-DuserTemplates=C:/Oracle/Middleware/wlserver/common/
templates/wls/wls.jar,C:/Oracle/Middleware/wlserver/common/templates/
wls/wls_webservice_jaxws.jar"

To run the Configuration Wizard in Quick Start mode on Windows systems, enter the following commands, where ORACLE_HOME is your Oracle home directory:

cd ORACLE_HOME/oracle_common/common/bin
config.cmd -target=config-oneclick

UNIX

To set CONFIG_JVM_ARGS on a UNIX or Linux system:

export CONFIG_JVM_ARGS="-DuserTemplates=template1,template2,template3, ..., templaten"

The following example uses the WebLogic Server base domain template and the Web Services JAX-WS template to create the domain:

export CONFIG_JVM_ARGS="-DuserTemplates=/Oracle/Middleware/wlserver/common/
templates/wls/wls.jar,/Oracle/Middleware/wlserver/common/templates/
wls/wls_webservice_jaxws.jar"

To run the Configuration Wizard in Quick Start mode on UNIX systems, enter the following commands, where ORACLE_HOME is your Oracle home directory:

cd ORACLE_HOME/oracle_common/common/bin
config.sh -target=config-oneclick

Table 2-4 shows the sequence of the Quick Start Configuration Wizard screens:

Table 2-4 Quick Start Configuration Screens

No. Screen When Does This Screen Appear? Perform the Following Action

1

Configuration

Always

Complete all fields and selections, and then click Create.

2

Configuration Progress

Always

Shows the progress of the domain creation.

When the process completes, click Next.

3

Configuration Success

Always

Review the domain creation results.

Click Finish to exit the Configuration Wizard.

Using Quick Start to Create the WebLogic Sample Domains

The Quick Start Wizard helps you create the WebLogic sample domains during the installation process. You can also run the wizard from the command line.

If you are running the wizard from the command line, you must create the sample domains one at a time. This process requires you to run the Quick Start Wizard three times to create all three domains.

Refer to Table 2-5 for the templates that you must include in the CONFIG_JVM_ARGS variable to create each domain. For example, to create the WebLogic Server Examples domain, enter the following commands, substituting your WebLogic Server home directory for WL_HOME:

set CONFIG_JVM_ARGS="-DuserTemplates=WL_HOME/common/
templates/wls/wls.jar,WL_HOME/common/templates/wls/wls_default.jar,
WL_HOME/common/templates/wls/wls_examples.jar"

cd ORACLE_HOME/oracle_common/common/bin
config.sh -target=config-oneclick

Table 2-5 Templates Required for WebLogic Sample Domains

To create this domain ... Include these templates ...

MedRec (Avitek Medical Records Sample Domain)

WL_HOME/common/templates/wls/wls.jar

WL_HOME/common/templates/wls/medrec.jar

MedRec Spring (Avitek Medical Records Sample Domain for Spring)

WL_HOME/common/templates/wls/wls.jar

WL_HOME/common/templates/wls/medrec_spring.jar

WebLogic Server Examples

WL_HOME/common/templates/wls/wls.jar

WL_HOME/common/templates/wls/wls_examples.jar