Administer > Administering WebSphere Commerce search > Deploy WebSphere Commerce search > Deploying the WebSphere Commerce search server


Deploy the WebSphere Commerce search server remotely (advanced deployment mode)

Overview

You can deploy the search server remotely by running the feature enablement scripts. This script deploys the search server remotely, depending on the environment.

For more information, see the following Redbook:

WebSphere Commerce V7.0 Feature Pack 2: Search solution overview and deployment


Deployment options

WebSphere Commerce Developer Embedded

Deploys search as part of the WebSphere Commerce Application.

Standard

Creates and deploys a separate search profile and Web module on the same machine as the WebSphere Commerce profile.

Advanced

Prepares the deployment package to copy and run the deployment scripts on a remote search machine, where a search profile and Web module is deployed.
For this task, only the Advanced deployment option applies. See Deploy WebSphere Commerce search for more information.


Before you begin

Ensure that you have installed the following WebSphere Commerce Feature Pack:


Procedure

  1. Prepare the WebSphere Commerce machine:

    1. Complete one of the following tasks:

      • AIXLinuxSolaris Log on as a WebSphere Commerce non-root user.

      • Windows Log on with a user ID that is a member of the Windows Administration group.

    2. Navigate to the following directory:

    3. Start the server1 instance:

      • AIXLinuxSolaris ./startServer.sh server1

      • Windows startServer.bat server1

    4. Run the enablement script:

      For enabling WebSphere Commerce search:

      • Windows config_ant.bat -buildfile WC_INSTALL/components/common/xml/enableFeature.xml -DinstanceName=instance -DfeatureName=foundation -DdbUserPassword=db_password [-DremoteSearchEngine=true] [-DsolrHome=solrhome]

      • AIXLinuxSolaris ./config_ant.sh -buildfile WC_INSTALL/components/common/xml/enableFeature.xml -DinstanceName=instance -DfeatureName=foundation -DdbUserPassword=db_password [-DremoteSearchEngine=true] [-DsolrHome=solrhome]

      Where:

      solrhome

      Optional: The location of the Solr home directory path which contains the index data of Solr. The value must be an absolute path.

      The default value is:

      Setting [-DremoteSearchEngine=true] indicates that the Advanced deployment option applies.

      For enabling WebSphere Commerce search store enhancements, see Enable starter store enhancements for more information.

    5. Verify the script runs successfully. If the script runs successfully:

      • AIXLinuxSolarisWindows The message BUILD SUCCESSFUL is displayed in the console and in the WC_INSTALL/instances/instance/logs/enablefoundation_timestamp.log file. See the file WC_INSTALL/instances/instance/logs/enablefoundation_timestamp.log for additional information.

  2. Prepare the remote machine:

    1. Copy the following directory from the WebSphere Commerce machine:

      • WC_INSTALL/components/foundation/subcomponents/search

    2. To the directory on the remote machine:

      • working_dir/search

    3. Install WebSphere Application Server and create a default profile.

    4. Install the database client that matches the WebSphere Commerce machine's database. Update the Path and CLASSPATH as necessary.

    5. Open the following file:

      • working_dir/search/deploy/properties/solr-deploy.properties

    6. Review the property values that were generated during feature enablement and update them if necessary.

    7. Run the following command to the deploy Solr WAR. The command creates a WebSphere Application Server profile, all necessary objects, and deploys the WAR:

      1. Navigate to the following directory:

      2. Run the deployment script:

        • AIXLinuxSolaris ws_ant.sh –buildfile working_dir/search/deploy/deploySearch.xml -DdbUserPassword=dbuserpwd [-DsolrHome=solrhome]

        • Windows ws_ant.bat –buildfile working_dir/search/deploy/deploySearch.xml -DdbUserPassword=dbuserpwd [-DsolrHome=solrhome]

        Where:

        dbuserpwd

        The password for the user connecting to the database.

        solrhome

        Optional: The location of the Solr home directory path which contains the index data of Solr. The value must be an absolute path.

        The default value is:

  3. Configure the Web server for the Solr application. Using a separate Web server requires you to install and configure another Web server and point it to the Solr profile plugin file.

    Currently, the configuration steps do not include the steps for configuring non-IHS Web servers such as IIS and SunOne. For other types of Web servers, consult the respective documentation to update the configuration accordingly.

    To configure the Web server for the Solr application, complete the following steps:

    1. Update the Web server configuration:

      1. For IBM HTTP Server, open the configuration file httpd.conf

      2. Add: Listen host_name:3737

      3. Point the plugin file to PROFILE_HOME/config/cells/instance_search_cell/nodes/instance_search_node/server1/solrWebserver/plugin-cfg.xml

  4. For Search Term Associations to function properly when deploying search remotely, complete the following steps:

    1. Create the mappings from the WebSphere Commerce server to the remote server:

      • AIXLinuxSolaris NFS mount from the WebSphere Commerce server to the Solr server.

      • Windows Map from the WebSphere Commerce server to the Solr server.

    2. Open the WebSphere Commerce configuration file and locate the SolrSearch node.

    3. Change solrHome to the directory of the solr search home mapped or mounted:

      For example, in Windows: <SolrSearch solrHome="W:/WebSphere/search/solr/home"/>

    4. Propagate your changes to the WebSphere Commerce configuration file.

  5. Test the search deployment by navigating to the following URL:

    Ensure the search server is running.

    http://host_name:3737/solr/Default/select?q=*%3A*
    

    If successful, you should receive a response resembling the following snippet:

    <response> −
    <lst name="responseHeader"> <int name="status">0</int> <int name="QTime">140</int> −
    <lst name="params"> <str name="q">*:*</str> </lst> </lst> <result name="response" numFound="0" start="0"/> </response> 
    


What to do next

After deploying your search server, perform the following tasks:

You must consider reviewing the following task to secure the search server:


Related tasks

Feature Pack 2 Deploy the WebSphere Commerce search server locally (standard deployment mode)

Feature Pack 2 Deploy the WebSphere Commerce search server remotely (Developer)


+

Search Tips   |   Advanced Search