自动化WebSphere插件配置:未解析httpd.conf中的${WAS_PLUGIN_DRIVER}变量

自动化WebSphere插件配置:未解析httpd.conf中的${WAS_PLUGIN_DRIVER}变量,websphere,websphere-8,ibm-connections,Websphere,Websphere 8,Ibm Connections,我正在使用CentOS 7上的Ansible进行HCL Connections 6.5的自动部署。它已经包括IBMIM、WAS(Dmgr+节点)、DB2和连接本身。HTTP服务器(IHS)已安装,但现在我需要对其进行配置。我需要使用WCT配置WebSphere插件 出于教育目的,我以前在另一台testserver上使用GUI模式进行了如下操作: cd /opt/IBM/WebSphere/Toolbox/WCT ./wct.sh cd /opt/IBM/WebSphere/Toolbox/WC

我正在使用CentOS 7上的Ansible进行HCL Connections 6.5的自动部署。它已经包括IBMIM、WAS(Dmgr+节点)、DB2和连接本身。HTTP服务器(IHS)已安装,但现在我需要对其进行配置。我需要使用WCT配置WebSphere插件

出于教育目的,我以前在另一台testserver上使用GUI模式进行了如下操作:

cd /opt/IBM/WebSphere/Toolbox/WCT
./wct.sh
cd /opt/IBM/WebSphere/Toolbox/WCT
./wctcmd.sh -tool pct -createDefinition -defLocPathname /opt/IBM/WebSphere/Plugins -response resp-file

现在我们得到了一个向导,它包含几个步骤,要求提供插件位置、Web服务器定义名称、HTTP服务器端口等等

使向导自动化 我发现 相当于
wtc.sh
的CLI,用于自动配置Web服务器。因此,我制作了以下响应文件

configType=remote
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=false
ihsAdminCreateUserAndGroup=true
ihsAdminPassword=password
ihsAdminPort=8008
ihsAdminUnixUserGroup=ihsadmin
ihsAdminUnixUserID=ihsadmin
mapWebServerToApplications=true
wasMachineHostname=cnx65.internal
webServerConfigFile1=/opt/IBM/HTTPServer/conf/httpd.conf
webServerDefinition=webserver1
webServerHostName=cnx65.internal
webServerOS=operating_system_value
webServerPortNumber=80
webServerSelected=ihs
然后像这样运行
wctcmd.sh

cd /opt/IBM/WebSphere/Toolbox/WCT
./wct.sh
cd /opt/IBM/WebSphere/Toolbox/WCT
./wctcmd.sh -tool pct -createDefinition -defLocPathname /opt/IBM/WebSphere/Plugins -response resp-file
它说该工具已成功执行。但是当我打开webserver config
/opt/IBM/HTTPServer/conf/httpd.conf
时,它添加了以下两行:

LoadModule was_ap22_module ${WAS_PLUGIN_DRIVER}
WebSpherePluginConfig /opt/IBM/WebSphere/Plugins/config/webserver1/plugin-cfg.xml
未定义此变量,在启动Web服务器时引发错误:

# /opt/IBM/HTTPServer/bin/apachectl start
httpd: Syntax error on line 915 of /opt/IBM/HTTPServer/conf/httpd.conf: Cannot load ${WAS_PLUGIN_DRIVER} into server: ${WAS_PLUGIN_DRIVER}: cannot open shared object file: No such file or directory
我假设出现
${WAS_PLUGIN_DRIVER}
表明
wctcmd.sh
出现了问题,因为我查看了另一个手动安装了Connections 6(使用GUI)的测试服务器,手动安装的服务器没有变量:

LoadModule was_ap22_module /opt/IBM/WebSphere/Plugins/bin/64bits/mod_was_ap22_http.so
WebSpherePluginConfig /opt/IBM/WebSphere/Plugins/config/webserver1/plugin-cfg.xml
一位在WebSphere/Connections领域拥有超过10年经验的顾问证实,
LoadModule是\u ap22\u module/opt/IBM/WebSphere/Plugins/bin/64bits/mod\u是\u ap22\u http。因此,当一切正常运行时,
是正确的,因此不应存在任何变量

问题
  • 为什么工具将
    ${WAS\u PLUGIN\u DRIVER}
    变量放在我的http配置中而不解析它们
  • 发生这种情况时,我做错了什么

  • 我发现我误解了
    webServerOS
    的操作系统值。我原以为脚本会自动检测操作系统,但文档说

    用于指定web服务器操作系统的webServerOS参数的有效值为Windows、Linux、Solaris、AIX、HPUX、OS390和OS400

    我还设置了
    webServerType=IHS
    。现在,它生成以下工作配置:

    LoadModule was_ap22_module /opt/IBM/WebSphere/Plugins/bin/64bits/mod_was_ap22_http.so
    WebSpherePluginConfig /opt/IBM/WebSphere/Plugins/config/webserver1/plugin-cfg.xml
    

    我发现我误解了
    webServerOS
    的操作系统值。我原以为脚本会自动检测操作系统,但文档说

    用于指定web服务器操作系统的webServerOS参数的有效值为Windows、Linux、Solaris、AIX、HPUX、OS390和OS400

    我还设置了
    webServerType=IHS
    。现在,它生成以下工作配置:

    LoadModule was_ap22_module /opt/IBM/WebSphere/Plugins/bin/64bits/mod_was_ap22_http.so
    WebSpherePluginConfig /opt/IBM/WebSphere/Plugins/config/webserver1/plugin-cfg.xml
    

    这和ansible有什么关系?去掉了那个标签,这样它就不会干扰ansible用户的反馈了。我首先添加它时考虑到了我的ansible playbook,我想在这里运行这个命令。但是为了简单起见,我只发布了没有Ansible部分的命令,因为它与问题无关。但是你是对的,这使Ansible标签过时了。这与Ansible有什么关系?将该标签删除,这样它就不会干扰Ansible用户的反馈。我首先添加了Ansible playbook,我想在其中运行此命令。但是为了简单起见,我只发布了没有Ansible部分的命令,因为它与问题无关。但你是对的,这让Ansible标签过时了。