Lesson 5.1: Configure eXtreme Scale servers to use the Liberty profile

To run the data grid in a Liberty profile, you must add the server feature to configure WebSphere® eXtreme Scale servers that use Liberty profile configuration files.

Procedure

  1. Configure a catalog server with default settings using the following attributes in the server.xml file, which tells eXtreme Scale to create and start a catalog server:
    <server description="eXtreme Scale Catalog Server with default settings">
    
        <!-- Enable features -->
        <featureManager>
            <feature>eXtremeScale.server-1.1</feature>
        </featureManager>
    
        <xsServer isCatalog="true" listenerPort="${com.ibm.ws.xs.server.listenerPort}" />
    
        <logging traceSpecification="*=info" maxFileSize="200" maxFiles="10" />
    
    </server>

    Notice that the listenerPort element is referenced in the server.xml; however, you configure this value in the bootstrap.properties file. It can be useful to separate elements such as port numbers out of the server.xml file so that multiple processes that run with an identical configuration can share the server.xml file, but still have unique settings.

  2. Configure the listenerPort attribute in the bootstrap.properties file.

    In the previous example, tracing is specified in the Liberty profile configuration, and the listenerPort attribute specifies a variable. This variable is configured in the bootstrap.properties file in the server configuration directory, wlp_install_root/usr/server/serverName. See the following example of the bootstrap.properties file:

    # Licensed Materials - Property of IBM
    #
    # "Restricted Materials of IBM"
    #
    # Copyright IBM Corp. 2011 All Rights Reserved.
    #
    # US Government Users Restricted Rights - Use, duplication or
    # disclosure restricted by GSA ADP Schedule Contract with
    # IBM Corp.
    #
    # ----------------------------------------------------------------
    #
    # port for the OSGi console
    # osgi.console=5678
    
    com.ibm.ws.xs.server.listenerPort=2809

    In this example, the osgi.console port is commented out, which means that the Liberty profile listens on the specified port for telnet clients to connect to an OSGi console. This behavior is useful for diagnosing OSGi-related errors.

  3. Configure the server.xml file using the same configuration that you might use for a stand-alone server configuration.
    In the server.xml file, specify the file path to the properties file in a serverProps attribute inside the com.ibm.ws.xs.server.config element. See the following example from the server.xml file:
    <server>
    ...
    <com.ibm.ws.xs.server.config ... serverProps="/path/to/myServerProps.properties" ... />
    </server>
    Restriction: The Liberty configuration model has restrictions in the way properties are specified. Therefore, if you require the following properties, you must specify them in the server properties file:
    foreignDomain.endpoints
    Specifies the names of catalog service domains to which you want to link in the multimaster replication topology.
    xioChannel.xioContainerTCPNonSecure.Port
    Specifies the unsecured listener port number of eXtremeIO on the server. If you do not set the value, an ephemeral port is used. This property is used only when the transportType property is set to TCP/IP. xioChannel.xioContainerTCPSecure.Port.
    Some properties that were formerly configurable in a stand-alone environment must be configured with the Liberty profile configuration instead of the eXtreme Scale configuration mechanisms.
    • Logging and tracing settings must be specified with the logging element in the server.xml file, rather than being specified in the eXtreme Scale server properties file or com.ibm.ws.xs.server.config element. For more information, see Liberty profile: Trace and logging in the WebSphere Application Server Information Center.
    • The working directory, like logging and tracing, is a server-wide setting, and therefore, they must be specified in a server-wide way.
    If the previous settings are specified incorrectly, eXtreme Scale logs a warning message, which indicates that the settings are ignored.
  4. (Optional) To configure security with your servers, then use the server.xml file to specify the path to the server properties file, which contains all of the security settings.
    When WebSphere eXtreme Scale is deployed in a WebSphere Application Server environment, you can simplify the authentication flow and transport layer security configuration from WebSphere Application Server. For more information, see Security integration with WebSphere Application Server.

Results

Your eXtreme Scale servers are ready to run in the Liberty profile.