Home

 

Change the context root of a feature


Overview

The Web address from which a Lotus Connections feature is available contains a default context root value. After installing the feature, you can change this value to a different context root to conform to corporate restrictions or policies that limit where server applications can be deployed and how they can be addressed.

This is an optional configuration. If you do decide to change the context roots of the features, be sure to do so before you map the features to the IBM HTTP Server or edit the IBM HTTP Server configuration file for any other reason, such as to redirect HTTP requests to support third-party authentication mechanisms.

For example, the Blogs feature is available from...

..by default. You can change that base Web address to...

..to differentiate it from another available blogging service or conform to corporate guidelines.


Change the context root of a feature

  1. Log into the WAS admin console for the server hosting the Connections feature for which you want to change the context root.

  2. Expand...

      Applications | Enterprise Applications | server_name | Web Module Properties | Context Root For Web Modules

  3. Edit the values in the Context Root column of the table to change the term that identifies the feature.

    Do not specify a single forward slash (/) as the full context root because it prevents features from being able to retrieve Atom feeds properly. Using the default application context ("/") is not supported.

  4. Click OK, and then click OK from the server properties page to save the change.

  5. Update the Connections configuration file to reflect this context root change. To do so, start the wsadmin client.

  6. Use the wsadmin client to access and check out the Connections configuration files.

    1. Access the Connections configuration file:

      • Stand-alone deployment:

          execfile("connectionsConfig.py")

      • Network deployment:

          execfile("WAS_HOME/profiles/Dmgr01/config/bin_lc_admin/connectionsConfig.py")

        If you are prompted to specify which server to connect to, type 1.

        This information is not used by the wsadmin client when you are making configuration changes.

    2. Check out the Connections configuration files...

      LCConfigService.checkOutConfig("<working_directory>","cell_name") where:

      • <working_directory> is the temporary working directory to which the configuration XML and XSD files are copied and are stored while you make changes to them. Use forward slashes to separate directories in the file path, even if you are using the Microsoft Windows operating system.

      • cell_name is the name of the WebSphere Application Server cell hosting the Connections feature. This argument is required even in stand-alone deployments. This argument is also case-sensitive, so type it with care. If you do not know the cell name, do one of the following to determine it:

        • Stand-alone deployment: From the file system...

            WAS_HOME\profiles\profile_name\config\cells\

        • Network deployment: Type the following command while in the wsadmin command processor:

            print AdminControl.getCell()

      For example:

      • AIX/Linux:

          LCConfigService.checkOutConfig("/opt/temp","foo01Cell01")

      • Microsoft Windows:

          LCConfigService.checkOutConfig("c:/temp","foo01Cell01")

  7. Update the value of the href prefix...

      LCConfigService.updateConfig("<web_module_name>.href.prefix", "<new_context_root_value>")

    where:

      <web_module_name>

      Name of the Web module for the feature. Each feature has one or more Web modules that are configured in WebSphere Application Server. The options are the following:

      Feature or Service name Web modules
      Activities activities
      Blogs blogs
      Communities communities
      Dogear dogear
      Files files
      Home page homepage, news
      Mobile mobile
      Profiles personTag, profiles
      Search search
      Wikis wikis

      <new_context_root_value>

      Value you defined for the feature's Web UI context root in Step 4.

      Do not specify a single forward slash (/) as the full context root because it prevents features from being able to retrieve Atom feeds properly.

    For example, to change the context root of the Profiles feature, you would use the following commands:

      LCConfigService.updateConfig("profiles.href.prefix","/contacts") LCConfigService.updateConfig("personTag.href.prefix","/contacts")

  8. Save your changes to the LotusConnections-config.xml file.

  9. After making changes, check the configuration files back in and do so during the same wsadmin session in which you checked them out for the changes to take effect.

  10. Files and Wikis only...

    1. Check out the Files and Wikis configuration files.

    2. Locate the following property:

        <security>
           <logout href="/files/ibm_security_logout" />
        </security>
        

    3. Change it to this:

        <security>
           <logout href="<new_context_root_value>/ibm_security_logout" />
        </security>
        

  11. To update existing links to uploaded files either update the old links manually, or redirect requests made to links that contain the old context root to links with the new one...

    1. Edit IHS_HOME/httpd.conf

    2. Uncomment the following line or add it if it is not present:

        LoadModule rewrite_module modules/mod_rewrite.so

    3. Add redirection rules for each feature for both HTTP and secure HTTP. For example

        RewriteEngine on RewriteRule /blogs/(.*) http://<myhost>/MyCoBlogs /$1 [R,L]
        Listen 0.0.0.0:443
        <VirtualHost *:443> RewriteEngine on RewriteRule /blogs/(.*) http://<myhost>/MyCoBlogs /$1 [R,L] ServerName <myhost>
        SSLEnable
        </VirtualHost> SSLDisable

    4. Save and close the httpd.conf file, and then restart the IBM HTTP Server.

  12. Regenerate the plugin-cfg.xml file for the IHS in the WAS admin console. To do so...

    1. Open the WAS admin console.

    2. Regenerate the plugin-cfg.xml file.

        Servers | Web servers | IHS_name | Generate Plug-in

    3. If necessary. click Propagate Plug-in

  13. Restart the IBM HTTP Server.

  14. Communities and Profiles only: If you change the context root for the Communities or Profiles feature, also update the property that defines the Web address of the feature for the extension services. To do so, start the wsadmin client, and complete the following steps:

    1. Access the Connections configuration file:

      • Stand-alone deployment:

          execfile("connectionsConfig.py")

      • Network deployment:

          execfile("WAS_HOME/profiles/Dmgr01/config/bin_lc_admin/connectionsConfig.py")

        If you are prompted to specify which server to connect to, type 1.

        This information is not used by the wsadmin client when you are making configuration changes.

    2. Check out the Connections configuration files...

        LCConfigService.checkOutConfig("<working_directory>","cell_name")

      where:

      • <working_directory> is the temporary working directory to which the configuration XML and XSD files are copied and are stored while you make changes to them. Use forward slashes to separate directories in the file path, even if you are using the Microsoft Windows operating system.

      • cell_name is the name of the WebSphere Application Server cell hosting the Connections feature. This argument is required even in stand-alone deployments. This argument is case-sensitive, so type it with care. If you do not know the cell name, do one of the following to determine it:

        • Stand-alone deployment: From the file system...

            WAS_HOME\profiles\profile_name\config\cells\

        • Network deployment: Type the following command while in the wsadmin command processor:

            print AdminControl.getCell()
            

        For example:

        • AIX or Linux:

            LCConfigService.checkOutConfig("/opt/temp","foo01Cell01")

        • Microsoft Windows:

            LCConfigService.checkOutConfig("c:/temp","foo01Cell01")

        • Communities only: Use the following command to change the value of the Web address for the Communities service extension:

            LCConfigService.updateConfig("communities.directory.service.extension.href", "<new_web_address_of_communities_feature>/dsx")

        • Profiles only: Use the following command to change the value of the Web address for the Profiles service extension:

            LCConfigService.updateConfig("profiles.directory.service.extension.href", "<new_web_address_of_profiles_feature>/dsx")

        • Check the configuration files back in...

            LCConfigService.checkInConfig()

        • To exit the wsadmin client, type exit at the prompt.

  15. Rebuild the search index by deleting the index and letting the indexing task recreate it when it runs. By default, the indexing task runs every 15 minutes.


Performing feature-specific tasks

 

Related tasks

Change configuration property values
Change configuration property values
Start the wsadmin client
Apply common configuration property changes
Delete the index

+

Search Tips   |   Advanced Search