Przyłączenie węzła (federacja) za pomocą addNode i DoNotDoAddNodeException oraz Upload retry limit exceeded for file


Podczas tworzenia profilu zarządzanego (ang. managed profile) poleceniem managedprofiles istnieje możliwość przyłączenia (federacja) do zarządcy środowiskiem Dmgr (ang. deployment manager). Najpierw tworzony jest sam profil (katalog konfiguracyjny), a następnie rozpoczyna się proces przyłączania. Parametrem, który kontroluje, czy wykonać proces przyłączenia jest -dmgrHost. Jeśli istnieje przyłączanie odbędzie się w ramach tworzenia profilu. Pełne polecenie do utworzenia profilu zarządzanego IBM WebSphere Process Server (WPS) to:

./bin/manageprofiles.sh -create -templatePath /opt/IBM/WebSphere/ProcServer/profileTemplates/managed.wbiserver -profileName Fabric01 -nodeName fabricNode02 -enableAdminSecurity true -adminUserName admin -adminPassword password -dbDelayConfig true -dbName wpsdb -dbHostName 10.10.10.144 -dbServerPort 1521 -dbType oracle10g -dbDriverType oracle_thin -dbJDBCClasspath /opt/IBM/WebSphere/ProcServer/oracleDriver -dmgrHost 10.10.10.141 -dmgrPort 8879 -dmgrAdminUserName admin -dmgrAdminPassword password

Nie jestem pewien, czy wszystkie parametry są konieczne, ale kluczem są parametry -create, -templatePath i wspomniany dmgrHost.

Niestety, ostatnim razem przy zestawianiu środowiska klastrowego WPSa 6.2 spotkałem się z następującym wyjątkiem: ADMU0111E: Program exiting with error: com.ibm.ws.management.tools.DoNotDoAddNodeException. Rozwiązaniem była synchronizacja zegarów na obu serwerach – Dmgr i węzła. A skąd ten wniosek? Wiadomo, że nie z samego wyjątku 🙂

Na zakończenie managedprofiles dostałem komunikat o jakimś błędzie i że odpowiedzi mam szukać w /opt/IBM/WebSphere/ProcServer/logs/manageprofiles/Fabric01_create.log. A tam:


<record>
<date>2009-09-03T19:52:57</date>
<millis>1252025577787</millis>
<sequence>10002</sequence>
<logger>com.ibm.ws.install.configmanager.actionengine.ant.utils.ANTLogToCmtLogAdapter</logger>
<level>WARNING</level>
<class>com.ibm.ws.install.configmanager.logging.LogUtils</class>
<method>logException</method>
<thread>10</thread>
<message>/opt/IBM/WebSphere/ProcServer/profileTemplates/managed.wbiserver/actions/executeManagedProfileSetup.ant:235: exec returned: 255
at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:591)
at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:617)
at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:452)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
at org.apache.tools.ant.Task.perform(Task.java:364)
at org.apache.tools.ant.Target.execute(Target.java:341)
at org.apache.tools.ant.Target.performTasks(Target.java:369)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1216)
at org.apache.tools.ant.Project.executeTarget(Project.java:1185)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:40)
at org.apache.tools.ant.Project.executeTargets(Project.java:1068)
at com.ibm.ws.install.configmanager.actionengine.ant.utils.InProcessAntRunner.runBuild(InProcessAntRunner.java:785)
at com.ibm.ws.install.configmanager.actionengine.ant.utils.InProcessAntRunner.start(InProcessAntRunner.java:234)
at com.ibm.ws.install.configmanager.actionengine.ANTAction.executeActionUsingAnInProcessANTCall(ANTAction.java:94)
at com.ibm.ws.install.configmanager.actionengine.ANTAction.executeAction(ANTAction.java:41)
at com.ibm.ws.install.configmanager.ConfigManager.executeAllActionsFound(ConfigManager.java:828)
at com.ibm.ws.install.configmanager.ConfigManager.executeActions(ConfigManager.java:547)
at com.ibm.ws.install.configmanager.ConfigManager.launch(ConfigManager.java:322)
at com.ibm.ws.install.configmanager.launcher.Launcher.mainForInProcessCMTCallers(Launcher.java:65)
at com.ibm.wsspi.profile.WSProfile.doAugment(WSProfile.java:707)
at com.ibm.wsspi.profile.WSProfile.stackCreate(WSProfile.java:332)
at com.ibm.wsspi.profile.WSProfile.create(WSProfile.java:171)
at com.ibm.ws.profile.cli.WSProfileCLICreateProfileInvoker.executeWSProfileAccordingToMode(WSProfileCLICreateProfileInvoker.java:86)
at com.ibm.ws.profile.cli.WSProfileCLIModeInvoker.invokeWSProfile(WSProfileCLIModeInvoker.java:211)
at com.ibm.wsspi.profile.WSProfileCLI.invokeWSProfile(WSProfileCLI.java:283)
at com.ibm.wsspi.profile.WSProfileCLI.main(WSProfileCLI.java:60)
</message>
</record>

i dalej w /opt/IBM/WebSphere/ProcServer/profileTemplates/managed.wbiserver/actions/executeManagedProfileSetup.ant na linii 235:

<target name="runAddNodeWithoutPortsFileWithUsernamePassword"
description="Runs the addNode utility to federate the profile without ports file."
if="RUN_WITHOUT_PORTFILE_WITH_USERPASSWORD" unless="hasBeenFederated">
<wscmtlog>Enter runAddNodeWithoutPortsFileWithUsernamePassword, username=${dmgrAdminUserName}, password=***** </wscmtlog>
<echo message="Federating to ${dmgrHost}:${dmgrPort} -username ${dmgrAdminUserName} -password ******, the output will be recorded in: ${profilePath}/logs/runAddNode.log"/>
<echo message="The federateLaterProcServer check was resolved to ${federateLaterProcServer}"/>

<exec executable="${ADDNODE_EXECUTABLE}" failonerror="true"
output="${profilePath}/logs/runAddNode.log">
<arg value="${dmgrHost}"/>
<arg value="${dmgrPort}"/>
<arg value="-username" />
<arg value="${dmgrAdminUserName}" />
<arg value="-password" />
<arg value="${dmgrAdminPassword}" />
<env key="WAS_USER_SCRIPT" value="${profilePath}/bin/${setupCmdLineName}"/>
<env key="PROFILE_CONFIG_ACTION" value="true"/>
<env key="Path" path="${WAS_HOME}${separatorFile}bin"/>
</exec>
<wscmtlog>Node was federated from runAddNodeWithoutPortsFileWithUsernamePassword </wscmtlog>
<property name="hasBeenFederated" value="true"/>
</target>

Stamtąd już rzut oka na /opt/IBM/WebSphere/ProcServer/profiles/Fabric01/logs/addNode.log i mam powód:

[9/3/09 19:52:57:074 CDT] 0000000a AdminTool E ADMU0111E: Program exiting with error: com.ibm.ws.management.tools.DoNotDoAddNodeException
at com.ibm.ws.management.tools.NodeFederationUtility.failAddNodeBecauseClocksNotInSync(NodeFederationUtility.java:1577)
at com.ibm.ws.management.tools.NodeFederationUtility.doCheckIfAddNodeIsOkToRun(NodeFederationUtility.java:1348)
at com.ibm.ws.management.tools.NodeFederationUtility.runTool(NodeFederationUtility.java:499)
at com.ibm.ws.management.tools.AdminTool.executeUtility(AdminTool.java:264)
at com.ibm.ws.management.tools.NodeFederationUtility.main(NodeFederationUtility.java:264)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.ibm.wsspi.bootstrap.WSLauncher.launchMain(WSLauncher.java:183)
at com.ibm.wsspi.bootstrap.WSLauncher.main(WSLauncher.java:90)
at com.ibm.wsspi.bootstrap.WSLauncher.run(WSLauncher.java:72)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
at org.eclipse.core.launcher.Main.run(Main.java:977)
at com.ibm.wsspi.bootstrap.WSPreLauncher.launchEclipse(WSPreLauncher.java:329)
at com.ibm.wsspi.bootstrap.WSPreLauncher.main(WSPreLauncher.java:92)

Szczególnie ta linia z at com.ibm.ws.management.tools.NodeFederationUtility.failAddNodeBecauseClocksNotInSync(NodeFederationUtility.java:1577). Wygląda na rozsynchronizowane czasy na obu serwerach. I faktycznie:

bash-3.2# date
Thu Sep 3 20:02:27 CDT 2009

bash-3.2# date
Thu Sep 3 13:02:48 CDT 2009

Po nastawieniu zegarów wszystko poszło dalej gładko. Więcej w addNode command best practices (niestety nie mogę znaleźć odpowiedniej strony w dokumentacji do wersji 6.2).

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s