現在的新版的WAS版本,將IHS加入到WAS的DMGR管理,一般有幾中方式,一是靜默式設置,二是,用WCT圖形化設置,三是,在DMGR通過增加遠程非受管節點的方式來將IHS加入到WAS的DMGR管理,讓DMGR可以控制IHS的啟停,下面,就說明靜默式設置試,就是在遇到IHS,無法使用圖形化界面時,如何在命令行,將IHS加入到WAS 的DMGR管理。
一、在IHS所在機器,靜默式安裝IM,IHS,PLUGIN,WCT工具軟件,這裡在本博客早前的文章有詳細說明,這裡不詳述。有興趣者,可以在本博客搜索就知道靜默式安裝方法。
二、在WAS 所在機器,靜默式安裝IM,WAS工具軟件,並創建相應Node和DMGR,這些在本博客早前的文章有詳細說明,這裡也不詳述,有興趣者,可以在本博客搜索就知道靜默式安裝方法。
三、編輯ihs遠程加入到DMGR的response.xml文件,內容如下:
configType=remote
enableAdminServerSupport=true
enableUserAndPass=true
enableWinService=false
ihsAdminCreateUserAndGroup=true
ihsAdminPassword=wasadmin
ihsAdminPort=8008
ihsAdminUnixUserGroup=wasadmin
ihsAdminUnixUserID=wasadmin
mapWebServerToApplications=true
wasMachineHostname=rhel6desk
webServerConfigFile1=/opt/IBM/HTTPServer/conf/httpd.conf
webServerDefinition=webserver1
webServerHostName=ctos6desk
webServerOS=Linux
webServerPortNumber=80
webServerSelected=ihs
留意紅色標註的參數,要跟實際環境參數匹配。
四、編輯安裝腳本:wct_shell.sh ,內容如下:
cd /opt/IBM/WebSphere/Toolbox/WCT/
./wctcmd.sh -tool pct -defLocPathname /opt/IBM/WebSphere/Plugins -defLocName webserver1 -createDefinition -response /opt/IBM/WebSphere/Toolbox/WCT/response.xml
五、執行wct_shell.sh ,如下所示:
[root@ctos6desk WCT]# chmod a+x wct_shell.sh
[root@ctos6desk WCT]# ./wct_shell.sh
正在導入定義位置…
已成功導入定義位置
正在啟動工具 pct …
工具執行已成功完成。
六、最後會在/opt/IBM/WebSphere/Plugins/bin下面生成一個configurewebserver1.sh .
七、通過ssh ,將configurewebserver1.sh ,傳到was機器的dmgr的bin目錄,如下所示:
[root@ctos6desk bin]# sftp root@192.168.179.17
Connecting to 192.168.179.17…
root@192.168.179.17’s password:
sftp> cd /opt/IBM/WebSphere
sftp> ls
AppServer Plugins Toolbox
sftp> cd AppServeer
Couldn’t canonicalise: No such file or directory
sftp> cd AppServer
sftp> cd profiles
sftp> ls
AppSrv01 Dmgr01
sftp> cd Dmgr01
sftp> cd bin
sftp> put configurewebserver1.sh
Uploading configurewebserver1.sh to /opt/IBM/WebSphere/AppServer/profiles/Dmgr01/bin/configurewebserver1.sh
configurewebserver1.sh 100% 2122 2.1KB/s 00:00
sftp> bye
八、執行configurewebserver1.sh,如下所示:
[root@rhel6desk bin]# ./configurewebserver1.sh
區域/單元名: <default>
Username: wasadmin
Password:
WASX7209I: 已使用 SOAP 連接器連接到節點 rhel6deskCellManager01 上的進程“dmgr”;進程的類型為:DeploymentManager
WASX7303I: 已將下列選項傳遞至腳本編製環境,它們將作為參數存儲在 argv 變量中:“[webserver1, IHS, /opt/IBM/HTTPServer, /opt/IBM/HTTPServer/conf/httpd.conf, 80, MAP_ALL, /opt/IBM/WebSphere/Plugins, unmanaged, ctos6desk-node, ctos6desk, linux]”。
Input parameters:
Web server name – webserver1
Web server type – IHS
Web server install location – /opt/IBM/HTTPServer
Web server config location – /opt/IBM/HTTPServer/conf/httpd.conf
Web server port – 80
Map Applications – MAP_ALL
Plugin install location – /opt/IBM/WebSphere/Plugins
Web server node type – unmanaged
Web server node name – ctos6desk-node
Web server host name – ctos6desk
Web server operating system – linux
IHS Admin port – 8008
IHS Admin user ID – “”
IHS Admin password – “”
IHS service name – “”
Creating the unmanaged node ctos6desk-node .
Unmanged node ctos6desk-node is created.
Creating the web server definition for webserver1 on node ctos6desk-node.
Parameters for administering IHS web server can also be updated using wsadmin script or admin console.
Web server definition for webserver1 is created.
Start computing the plugin properties ID.
Plugin properties ID is computed.
Start updating the plugin install location.
Plugin install location is updated.
Start updating the plugin log file location.
Plugin log file location is updated.
Start updating the RemoteConfigFilename location.
Plugin remote config file location is updated.
Start updating the RemoteKeyRingFileName location.
Plugin remote keyring file location is updated.
Start saving the configuration.
Configuration save is complete.
Computed the list of installed applications.
Processing the application DefaultApplication.
Get the current target mapping for the application DefaultApplication.
Computed the current target mapping for the application DefaultApplication.
Start updating the target mappings for the application DefaultApplication.
ADMA5075I: 已開始編輯應用程序 DefaultApplication。
Target mapping is not updated for the application DefaultApplication, exception = com.ibm.ws.scripting.ScriptingException: com.ibm.websphere.management.exception.AdminException
javax.management.MBeanException
com.ibm.websphere.management.exception.AdminException: ADMA5026E: 沒有在模塊 DefaultWebApplication.war+WEB-INF/web.xml 的 ObjectName WebSphere:cell=rhel6deskCell01,node=rhel6deskCellManager01,server=server1 中指定有效目標。
Start saving the configuration.
Configuration save is complete.
九、然後登陸WAS的DMGR管理控制台,就可以在WEB服務器里,新加入的webserver1服務器,正常的話,就可以成功生成插件和分發插件,並且通過DMGR來控制IHS的啟停。
以下文章點擊率最高
Loading…