Set a global Web server plug-in configuration file


 

+

Search Tips   |   Advanced Search

 

If all of the appservers in a cell use the same Web server to route requests for dynamic content, such as servlets, from Web apps to appservers, we can create a global Web server plug-in configuration file for that cell. The resulting plugin-cfg.xml file is located in...

PROFILE_HOME/config/cells

You must update the global Web server plug-in configuration file whenever you:

To update the settings for a global Web server plug-in, we can either use the Update global Web server plug-in configuration page in the admin console, or run..

PROFILE_HOME/config/cells/GenPluginCfg.sh

Both methods create a plugin-cfg.xml file.

To use the Update global Web server plug-in configuration page in the admin console:

  1. Click Environment > Update global Web server plug-in configuration.

  2. Click OK to update plugin-cfg.xml.

  3. Click View or download the current Web server plug-in configuration file to view or download the current version of this file. We can select this option to:

    • View the current version of the file before you update it.
    • View the file after it is updated.
    • Download a copy of this file to a remote machine.

 

Results

Regenerate the configuration might take a while to complete. After it finishes, all objects in the admin cell use their newest settings, which the Web server can access. Whether triggered manually or occurring automatically, plug-in regeneration requires about 30 to 60 seconds to complete when the appserver is on the same physical machine (node) as the Web server. In other cases, it takes more time.

The delay is important because it determines how soon the new plug-in configuration takes effect. Suppose you add a new served path for a servlet, then regenerate the plug-in configurations. The regeneration requires 40 seconds, after which a user should be able to access the servlet by the new served path.

For an HTTP plug-in, the length of the delay is determined by the Refresh Interval attribute of the Config element in plugin-cfg.xml. The plug-in polls the disk, or file system, at this interval to see whether the configuration has changed. The default interval is 60 seconds. To regenerate the plug-in configuration requires twice the refresh interval.

In a development environment in which we are frequently changing settings in the admin console, IBM recommends set the refresh interval to 3 to 5 seconds.

In a production environment, set a longer refresh interval, perhaps as long as 30 minutes, depending on the frequency of changes.

 

What to do next

We might need to stop the appservers in the cell and then start the appservers again before the changes to the plug-in configuration go into effect.

If the Web server is running on a remote machine, click View or download the current Web server plug-in configuration file to download a copy of plugin-cfg.xml to a that machine.

When the deployment manager is installed on a machine that is remote from where WAS is installed, one of the following solutions must be implemented in order for plugin-cfg.xml to retain the appserver directory structures, and not assume those of the dmgr after the plug-in is regenerated and a full synchronization occurs. The plugin-cfg.xml file is located in...

appserver /config/cells

Command line:

At a command prompt, enter the following command to change the DeploymentManager/bin directory and type on the machine where the dmgr is installed. This command creates or updates plugin-cfg.xml, and changes all of the directories in plugin-cfg.xml to APP_ROOT directories.

GenPluginCfg -destination.root <APP_ROOT>

For example, issue the following command from the DeploymentManager/bin directory.

GenPluginCfg -destination.root "E:\WebSphere\AppServer"

plugin-cfg.xml file:

Edit plugin-cfg.xml, located in...

APP_ROOT/DeploymentManager/config/cells

...to point to the correct directory structure for the log file, keyring, and stashfile.

Perform a full synchronization so plugin-cfg.xml is replicated in all the nodes. Use scripting or the admin console to synchronize the nodes in the cell.

The dmgr plugin-cfg.xml file can point to the appserver directories without any conflict.

 

Related tasks

Change the appserver configuration using wsadmin
Update the global Web server plug-in configuration setting
Communicating with Web servers

 

Related

GenPluginCfg