[AIX Solaris HP-UX Linux Windows]

使用 pct 工具配置 Web 服务器插件

WCT 命令用于调用 -tool 参数指定的命令行工具。您可以使用 WCT 命令并指定 pct 工具将 Web 服务器配置为使用应用程序服务器作为托管服务器。

过程

将 Web 服务器配置为使用应用程序服务器作为托管服务器。
WCT 命令的位置
产品包含以下用于设置环境和调用 WCT 命令的脚本。
  • [Windows]WCT_install_root\WCT\wctcmd.bat
  • [Linux]WCT_install_root/WCT/wctcmd.sh
调用 pct 工具时 WCT 命令的语法
[Windows]
wctcmd.bat
      -tool pct
      -defLocPathname definition_location_pathname
      -defLocName definition_location_name
      -importDefinitionLocation
      -removeDefinitionLocation definition_location_name
      -listDefinitionLocations
      -createDefinition
      -deleteDefinition webserver_definition_name
      -listDefinitions
      -response response_file
[Linux]
./wctcmd.sh
      -tool pct
      -defLocPathname definition_location_pathname
      -defLocName definition_location_name
      -importDefinitionLocation
      -removeDefinitionLocation definition_location_name
      -listDefinitionLocations
      -createDefinition
      -deleteDefinition webserver_definition_name
      -listDefinitions
      -response response_file
调用 pct 工具时 WCT 命令的参数
-tool pct
指定要启动的工具的名称(此名称已向 WCT 命令注册)

此参数是必需的。

-defLocName definition_location_name
指定插件运行时根目录位置的逻辑名

创建或删除定义时,此参数是必需的。

-defLocPathname definition_location_pathname
指定现有插件运行时根目录位置的绝对路径名

创建或删除定义时,此参数是必需的。

-importDefinitionLocation
指定要将 Web 服务器插件运行时位置导入到工具注册表中

在此操作的执行过程中,将创建新的定义。

用法示例:

[Windows]
wctcmd.bat -tool pct -importDefinitionLocation -defLocPathname C:\data\IBM\WebSphere\Plugins -defLocName DefinitionLocationName -response C:\IBM\WebSphere\tools\WCT\responsefile.txt
[Linux]
./wctcmd.sh -tool pct -importDefinitionLocation -defLocPathname /opt/IBM/WebSphere/Plugins -defLocName DefinitionLocationName -response /opt/IBM/WebSphere/tools/WCT/responsefile.txt
-listDefinitionLocations
指定要生成所有定义位置的列表

用法示例:

[Windows]
wctcmd.bat -tool pct -listDefinitionLocations
[Linux]
./wctcmd.sh -tool pct -listDefinitionLocations
-removeDefinitionLocation
指定 pct 工具应该移除定义位置

移除定义位置时将使用此参数。

用法示例:

[Windows]
wctcmd.bat -tool pct -removeDefinitionLocation -defLocPathname C:\data\IBM\WebSphere\Plugins
[Linux]
./wctcmd.sh -tool pct -removeDefinitionLocation -defLocPathname /opt/IBM/WebSphere/Plugins
[Windows]
wctcmd.bat -tool pct -removeDefinitionLocation -defLocName DefinitionLocationName
[Linux]
./wctcmd.sh -tool pct -removeDefinitionLocation -defLocName DefinitionLocationName
-createDefinition
指定要创建新的 Web 服务器定义

用法示例:

[Windows]
wctcmd.bat -tool pct -createDefinition -defLocName DefinitionLocationName -response C:\IBM\WebSphere\tools\WCT\responsefile.txt
[Linux]
./wctcmd.sh -tool pct -createDefinition -defLocName DefinitionLocationName -response /opt/IBM/WebSphere/tools/WCT/responsefile.txt
-deleteDefinition webserver_definition_name
指定要删除的唯一 Web 服务器插件定义

删除现有定义时将使用此参数。

definition_name 是必需的。下列其中一个参数也是必需的:
  • -defLocName definition_location_name
  • -defLocPathname definition_location_pathname
如果同时提供了这两个参数值,那么将使用第一个参数值。如果提供的第一个值未能通过验证检查,那么命令将失败,并显示一条错误消息。

用法示例:

[Windows]
wctcmd.bat -tool pct -defLocPathname C:\data\IBM\WebSphere\Plugins -defLocName DefinitionLocationName -deleteDefinition WebServerDefinitionName
[Linux]
./wctcmd.sh -tool pct -defLocPathname /opt/IBM/WebSphere/Plugins -defLocName DefinitionLocationName -deleteDefinition WebServerDefinitionName
-listDefinitions
指定要生成所有定义的列表

用法示例:

[Windows]
wctcmd.bat -tool pct -listDefinitions -defLocName DefinitionLocationName
[Linux]
./wctcmd.sh -tool pct -listDefinitions -defLocName DefinitionLocationName
-response response_file
指定包含 tool 自变量的响应文件

创建定义时,此参数是必需的。

注意:
  • 命令行自变量区分大小写。
  • 如果自变量接受包含空格的值,那么该值必须括在双引号 (" ") 中。
-logLevel integer_value
指示日志输出的详细程度。自变量值可以是 1 到 7 的整数,其中 7 是最详细的日志级别。
pct 工具的参数
常规参数
参数
configType
指定配置类型
local_standalone
WebSphere® Application Server 和 Web 服务器处于同一台机器上
remote
WebSphere Application Server 和 Web 服务器处于不同机器上
local_distributed
WebSphere Application Server 上的概要文件已联合到 Deployment Manager
wasExistingLocation
指定 WebSphere Application Server 安装主目录的位置

此选项仅对本地配置类型有效。

WebSphere Application Server 安装主目录的位置

webServerSelected
指定要配置的 Web 服务器

仅指定一个要配置的 Web 服务器。

apache22
Apache Web Server V2.2
domino7
Lotus® Domino® Web Server V7.0

在 HP-UX 或 Solaris x64 (x86_64) 上不受支持

domino8
Lotus Domino Web Server V8.0

在 HP-UX 或 Solaris x64 (x86_64) 上不受支持

ihs
IBM® HTTP Server V7.0
iis6
Microsoft Internet Information Services V6

在 Windows 上受支持

iis7
Microsoft Internet Information Services V7

在 Windows 上受支持

iis8
Microsoft Internet Information Services V8

在 Windows 上受支持

sunone
Sun Java™ System Web Server V6.1 或 Sun Java System Web Server V7.0
ihsAdminPort
指定 HTTP 管理端口号

仅当配置 IHS 时,才应指定此值。

HTTP 管理端口号

ihsAdminUserID
指定 IHS 管理服务器的 IHS 管理员用户标识

仅当配置 IHS 时,才应指定此值。

IHS 管理服务器的 IHS 管理员用户标识

ihsAdminUserGroup
指定 IHS 管理服务器的用户组

仅当配置 IHS 时,才应指定此值。

IHS 管理服务器的用户组

webServerConfigFile1
指定第一个 Web 服务器配置文件

指定的文件必须存在。

apache
httpd.conf
限制: 要成功配置服务器,必须将配置文件的名称保留为 httpd.conf
domino7
notes.jar
domino8
notes.jar
ihs
httpd.conf
限制: 要成功配置服务器,必须将配置文件的名称保留为 httpd.conf
sunone
magnus.conf
webServerConfigFile2
指定第二个 Web 服务器配置文件

指定的文件必须存在。

domino7
names.jar
domino8
names.jar
sunone
obj.conf
webServerPortNumber
指定要配置的 Web 服务器的 Web 服务器端口

要配置的 Web 服务器的 Web 服务器端口

dominoUserID
指定 Domino V7.0 或 V8.0 用户标识

Domino V7.0 或 V8.0 用户标识

webServerDefinition
指定 Web 服务器定义名称

在 Web 服务器定义名称中,不允许存在任何空格。

Web 服务器定义名称(不含任何空格)

wasMachineHostName
指定 WebSphere Application Server 机器主机名

对于本地独立安装类型,可以省略此指定。

对于远程安装类型:
"hostname"

安装将使用机器上的 hostname 主机名。

对于本地安装类型:
""

将使用目标安装机器的主机名。

注意: 如果您使用 WCT 命令创建多个 Web 服务器并根据需要在 Web 服务器机器上运行 WCT,那么每一个 Web 服务器的主机名都是派生的主机名(基于您对其查询主机名的操作系统的相同类型)。

以这种方式运行 WCT 会导致创建两个具有相同主机名的脚本文件,这两个脚本文件将用于创建节点和 serverIndex.xml 文件。

通过同一机器上的两个 Web 服务器,您将具有两个网络 IP 地址,您可能要对这两个 IP 地址使用唯一的主机名。

因为主机名是派生的名称并且您不会接收到 Web 服务器主机名的提示,所以 WCT 工具及相关联的 configurewebserverx.bat/sh 脚本将使用相同的主机名来创建节点和 serverIndex.xml 文件。

为了确保您在同一机器上创建的两个 Web 服务器具有不同的网络 IP 地址,请转至管理控制台并执行下列操作:
  1. 服务器 > Web 服务器 > webserverName
  2. 单击“端口”
  3. 如果是受管节点,请单击 WEBSERVER_ADDRESS。如果是非受管节点,请单击 WEBSERVER_ADMIN_ADDRESS
  4. 更改 IP 地址(主机名)。
  5. 单击确定,然后单击保存
高级参数(仅可用于静默安装)
参数
mapWebserverToApplications
指定是否将所有已部署的现有应用程序映射到 Web 服务器

如果此参数未设置为有效选项,那么安装程序会将其设置为 true 并继续安装。

true
Web 服务器定义将作为目标映射到已部署的现有应用程序(例如 snoop 和 hit count)。(推荐)
false
不将任何应用程序映射到 Web 服务器定义。
webServerHostName
对于用户在机器上设置了多个 Web 服务器主机名的高级方案,此参数指定用于配置的 Web 服务器主机名
""
安装将解析为在机器上检测到的主机名。(推荐)
"hostname"
安装将使用机器上的 hostname 主机名。
webServerInstallArch
指定 Web 服务器安装体系结构
"32"
对于 32 位 Web 服务器安装有效
"64"
对于 64 位 Web 服务器安装有效
""
将使用 Web 服务器机器的体系结构
profileName
指定要配置的 WebSphere Application Server 概要文件的名称
"profile_name"
必须输入现有 WebSphere Application Server 概要文件的名称。

保留空字符串将导致安装程序使用缺省概要文件。

此选项仅在本地安装方案中有效。

ihsAdminPassword
指定要配置的 IHS 管理服务器的用户密码

仅当配置 IHS 时,才应指定此值。

"IHS_admin_password"
必须输入将用来配置 IHS 管理服务器的密码。
enableAdminServerSupport
指定是否配置 IHS 管理服务器

仅当配置 IHS 时,才应指定此值。

true
将启用支持,并且将配置 IHS 管理服务器。
false
不启用支持,并且不配置 IHS 管理服务器。
enableUserAndPass
指定是否对以下配置方式启用支持,即使用用户标识和密码作为凭证来配置 IHS 管理服务器。

仅当配置 IHS 时,才应指定此值。

true
支持使用给定用户标识和密码来配置 IHS 管理服务器。

必须提供其他相关凭证。

false
不支持使用给定用户标识和密码来配置 IHS 管理服务器。

不需要其他的值。

webServerType
指定要配置的 Web 服务器的类型

仅指定一个要配置的 Web 服务器。

APACHE
Apache Web Server V2.2
DOMINO
Lotus Domino Web Server V7.0 或 V8.0

在 HP-UX 或 Solaris x64 (x86_64) 上不受支持

IHS
IBM HTTP Server V7.0
IIS
Microsoft Internet Information Services V6、V7 或 V8

在 Windows 上受支持

SUNJAVASYSTEM
Sun Java System Web Server V6.1 或 V7.0
ihsWindowsStartupType
指定要在 Windows 上创建的 IHS 管理服务的启动类型

仅当配置 IHS 时,才应指定此值。

仅用于 Windows 操作系统。

auto
此服务将在系统引导时自动启动。
demand
此服务仅在接收到请求时启动。
ihsAdminWinUserID
指定将用来在 Windows 上配置 IHS 管理服务器的用户的标识

仅当配置 IHS 时,才应指定此值。

仅用于 Windows 操作系统。

"IHS_admin_user_ID"
必须输入将用来配置 IHS 管理服务器的名称。
ihsAdminWinPassword
指定将用来在 Windows 上配置 IHS 管理服务器的用户的密码

仅当配置 IHS 时,才应指定此值。

仅用于 Windows 操作系统。

"IHS_admin_password"
必须输入将用来配置 IHS 管理服务器的密码。
enableWinService
指定是否将 IHS 管理服务器配置成作为 Windows 服务运行

仅当配置 IHS 时,才应指定此值。

仅用于 Windows 操作系统。

true
支持将 IHS 管理服务器配置为 Windows 服务
false
不支持将 IHS 管理服务器配置为 Windows 服务。
注: 在运行 WCT 命令之后,Web 服务器便配置为使用应用程序服务器作为托管服务器。WCT 命令还会在包含配置文件的目录中创建新的响应文件。此响应文件可能包含两个未记录的条目 defLocPathnameprofilePath,它们在功能上不受产品支持。新的响应文件包含用来创建 Web 服务器配置的信息。
使用 pct 工具将 IHS Web 服务器配置为使用应用程序服务器作为托管服务器的示例:
  • [Windows]wctcmd.bat -tool pct -defLocPathname C:\data\IBM\WebSphere\Plugins -defLocName someDefinitionLocationName -createDefinition -response C:\IBM\WebSphere\tools\WCT\responsefile.txt
  • [Linux]./wctcmd.sh -tool pct -defLocPathname /opt/IBM/WebSphere/Plugins -defLocName someDefinitionLocationName -createDefinition -response /opt/IBM/WebSphere/tools/WCT/responsefile.txt

以下是用于 IHS 本地插件配置的响应文件的内容示例。webServerOS 参数(用来指定 Web 服务器操作系统)的有效值为 Windows、Linux, Solaris、AIX®、HPUX、OS390 和 OS400。

[AIX][HP-UX][Linux][Solaris]
configType=local_standalone
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=false
ihsAdminCreateUserAndGroup=true
ihsAdminPassword=******
ihsAdminPort=8008
ihsAdminUnixUserGroup=grp101
ihsAdminUnixUserID=user1
mapWebServerToApplications=true
profileName=AppSrv01
wasExistingLocation=/opt/IBM/WebSphere/AppServer85
webServerConfigFile1=/opt/IBM/HTTPServer/conf/httpd.conf
webServerDefinition=webserver1
webServerHostName=local.ibm.com
webServerOS=operating_system_value
webServerPortNumber=80
webServerSelected=ihs
[Windows]
configType=local_standalone
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=true
ihsAdminPassword=******
ihsAdminPort=8008
ihsAdminUserID=admin1
ihsWindowsPassword=******
ihsWindowsStartupType=auto
ihsWindowsUserID=user1
mapWebServerToApplications=true
profileName=AppSrv01
wasExistingLocation=D:\\IBM\\WebSphere\\AppServer85
webServerConfigFile1=D:\\IBM\\HTTPServer\\conf\\httpd.conf
webServerDefinition=webserver1
webServerHostName=local.ibm.com
webServerInstallArch=32
webServerPortNumber=80
webServerSelected=ihs

以下是用于 IHS 远程插件配置的响应文件的内容示例。webServerOS 参数(用来指定 Web 服务器操作系统)的有效值为 Windows、Linux, Solaris、AIX、HPUX、OS390 和 OS400。

[AIX][HP-UX][Linux][Solaris]
configType=remote
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=false
ihsAdminCreateUserAndGroup=true
ihsAdminPassword=******
ihsAdminPort=8008
ihsAdminUnixUserGroup=grp101
ihsAdminUnixUserID=user1
mapWebServerToApplications=true
wasMachineHostname=192.168.1.2
webServerConfigFile1=/opt/IBM/HTTPServer/conf/httpd.conf
webServerDefinition=webserver1
webServerHostName=remote.ibm.com
webServerOS=operating_system_value
webServerPortNumber=80
webServerSelected=ihs
[Windows]
configType=remote
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=true
ihsAdminPassword=******
ihsAdminPort=8008
ihsAdminUserID=admin1
ihsWindowsPassword=******
ihsWindowsStartupType=auto
ihsWindowsUserID=user1
mapWebServerToApplications=true
wasMachineHostname=192.168.1.2
webServerConfigFile1=D:\IBM\HTTPServer\conf\httpd.conf
webServerDefinition=webserver1
webServerHostName=remote.ibm.com
webServerInstallArch=32
webServerOS=windows
webServerPortNumber=80
webServerSelected=ihs

下一步做什么

最佳实践 最佳实践: 如果您的机器具有多个主机名和 IP 地址,那么您可以使用 pct 工具。但是,必须使用下列过程在通过 PCT 图形用户界面配置 Web 服务器之后设置主机名:
  1. 单击端口
  2. 单击 WEBSERVER_ADDRESS。如果是受管方式,请单击 WEBSERVER_ADMIN_ADDRESS
  3. 更改主机名。
  4. 单击确定进行保存。
best-practices

指示主题类型的图标 任务主题



时间戳记图标 最近一次更新时间: last_date
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=cord&product=was-nd-mp&topic=tins_pctcl_using
文件名:tins_pctcl_using.html