Monthly Archives: November 2013

WebSphere 8.5 – Managing profiles using ‘manageprofiles’ command

Creating Deployment Manager profile

manageprofiles.bat -create -profileName dmgr -profilePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\dmgr" -templatePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profileTemplates\management" -serverType DEPLOYMENT_MANAGER  -cellName was85hostCell01 -nodeName was85hostCellManager01 -hostName was85host01 -enableAdminSecurity true -adminUserName wasadmin -adminPassword web1sphere

Creating Node1 server profile

manageprofiles.bat -create -profileName profile1 -profilePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile1" -templatePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profileTemplates\default" -serverName server1  -nodeName was85hostNode01 -hostName was85host01 -enableAdminSecurity true -adminUserName wasadmin -adminPassword web1sphere
INSTCONFSUCCESS: Success: Profile profile11 now exists. Please consult c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile1\logs\AboutThisProfile.txt for more information about this profile.

Creating Node2 server profile

manageprofiles.bat -create -profileName profile12 -profilePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile2" -templatePath "c:\Program Files (x86)\IBM\WebSphere\AppServer\profileTemplates\default" -serverName server2 -nodeName was85hostNode02 -hostName was85host01 -enableAdminSecurity true -adminUserName wasadmin -adminPassword web1sphere
INSTCONFSUCCESS: Success: Profile profile12 now exists. Please consult c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile2\logs\AboutThisProfile.txt for more information about this profile.

Federate a node into the cell

c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile2\bin>addNode.bat was85host01 -username wasadmin -password web1sphere
ADMU0116I: Tool information is being logged in file c:\Program Files (x86)\IBM\WebSphere\AppServer\profiles\profile2\logs\addNode.log
ADMU0128I: Starting tool with the profile12 profile
CWPKI0308I: Adding signer alias "CN=was85host01, OU=Root Certifi" to local keystore "ClientDefaultTrustStore" with the following SHA digest: 4A:2F:F5:1E:C1:48:0F:E4:94:75:82:0C:44:FD:63:CC:7A:B2:88:2B
CWPKI0309I: All signers from remote keystore already exist in local keystore.
ADMU0001I: Begin federation of node was85hostNode02 with Deployment Manager at was85host01:8879.
ADMU0009I: Successfully connected to Deployment Manager Server: was85host01:8879
ADMU0505I: Servers found in configuration:
ADMU0506I: Server name: server2
ADMU2010I: Stopping all server processes for node was85hostNode02
ADMU0512I: Server server2 cannot be reached. It appears to be stopped.
ADMU0024I: Deleting the old backup directory.
ADMU0015I: Backing up the original cell repository.
ADMU0012I: Creating Node Agent configuration for node: was85hostNode02
ADMU0014I: Adding node was85hostNode02 configuration to cell: was85hostCell01
ADMU0016I: Synchronizing configuration between node and cell.
ADMU0018I: Launching Node Agent process for node: was85hostNode02
ADMU0020I: Reading configuration for Node Agent process: nodeagent
ADMU0022I: Node Agent launched. Waiting for initialization status.
ADMU0030I: Node Agent initialization completed successfully. Process id is: 3448
ADMU0505I: Servers found in configuration:
ADMU0506I: Server name: nodeagent
ADMU0506I: Server name: server2

ADMU0300I: The node was85hostNode02 was successfully added to the was85hostCell01 cell.

ADMU0306I: Note:
ADMU0302I: Any cell-level documents from the standalone was85hostCell01 configuration have not been migrated to the new cell.
ADMU0307I: You might want to:
ADMU0303I: Update the configuration on the was85hostCell01 Deployment Manager with values from the old cell-level documents.

ADMU0306I: Note:
ADMU0304I: Because -includeapps was not specified, applications installed on the standalone node were not installed on the new cell.
ADMU0307I: You might want to:
ADMU0305I: Install applications onto the was85hostCell01 cell using wsadmin $AdminApp or the Administrative Console.

ADMU0003I: Node was85hostNode02 has been successfully federated.

Create a cluster from existing servers

Please run following Jython commands on wsadmin script tool.

server1 = AdminConfig.getid('/Cell:was85hostCell01/Node:was85hostNode01/Server:server1/')
server2 = AdminConfig.getid('/Cell:was85hostCell01/Node:was85hostNode02/Server:server2/')
AdminConfig.convertToCluster(server1, 'myCluster1')
AdminConfig.convertToCluster(server2, 'myCluster1')
AdminConfig.save()

Create a new  cluster member 

cluser_id = AdminConfig.getid('/ServerCluster:myCluster01/') 
node_id = AdminConfig.getid('/Node:mynode/') 
AdminConfig.createClusterMember(cluster_id, node_id, [['memberName', 'server3']])
Array ( [marginTop] => 100 [pageid] => @techish1 [alignment] => left [width] => 292 [height] => 300 [color_scheme] => light [header] => header [footer] => footer [border] => true [scrollbar] => scrollbar [linkcolor] => #2EA2CC )