Wednesday 29 November 2017

IBM UrbanCode Deploy - Where do your agents come from ?

I had a bit of a brain fade today, trying to work out from where to download the Agent code for IBM UrbanCode Deploy (UCD).

I'm using the latest UCD 6.2.6, and have the server up-and-running.

Now I want to pop an agent onto a target box ….

I looked at the downloads on the IBM website ( as an IBMer, we have an internal equivalent of Passport Advantage ), so I was looking at this: -

IBM UrbanCode Deploy 6.2.6 Multiplatform Multilingual eAssembly (CJ2BYML)

which includes: -

IBM UrbanCode Deploy 6.2.6 Multiplatform Multilingual (CNM8JML )

which I'd used to install the UCD Server: -

and this: -

IBM UrbanCode Cloud Agent Packages 6.2.6 Multiplatform Multilingual (CNM8PML )

about which I wasn't so sure ( apart from that it's a 2 GB download ! )

Thankfully, the IBM Knowledge Centre came to my rescue: -


which said, in part: -


so I hit up my UCD Server: -


to get this: -

I grabbed the URL of the Agent: -


and pulled this onto the box: -


and installed the agent: -

/tmp/ibm-ucd-agent-install/install-agent.sh 

into: -

/opt/ibm/UCD/agent/

so that's all good then :-)

DB2 - The Hanging Creation of Instances

Having freshly installed the latest DB2 11.1 on a Linux VM, I found that the instance creation process: -

/opt/ibm/db2/V11.1/instance/db2icrt -a SERVER -u db2fenc1 db2inst1

kept hanging e.g.

...
DBI1446I  The db2icrt command is running.


DB2 installation is being initialized.

 Total number of tasks to be performed: 4 
Total estimated time for all tasks to be performed: 309 second(s) 

Task #1 start
Description: Setting default global profile registry variables 
Estimated time 1 second(s) 
Task #1 end 

Task #2 start
Description: Initializing instance list 
Estimated time 5 second(s) 

Task #2 end 

Task #3 start
Description: Configuring DB2 instances 
Estimated time 300 second(s) 

...

even after a reboot: -

...
DBI1446I  The db2icrt command is running.


DB2 installation is being initialized.

….

I had a quick bit of inspiration, and checked whether I could ping the box's hostname: -

 ping `hostname`

which ran for ever, and failed to respond :-(

So I added the hostname to /etc/hosts : -

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4  ucd.uk.ibm.com  ucd

( noting that I'm merely mapping the hostnames to the loopback / localhost address of 127.0.0.1 which is typically not good practice )

I re-tested using ping: -

ping `hostname`

PING localhost (127.0.0.1) 56(84) bytes of data.
64 bytes from localhost (127.0.0.1): icmp_seq=1 ttl=64 time=0.048 ms
64 bytes from localhost (127.0.0.1): icmp_seq=2 ttl=64 time=0.128 ms
^C
--- localhost ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 0.048/0.088/0.128/0.040 ms


and then retried the db2icrt process: -

/opt/ibm/db2/V11.1/instance/db2icrt -a SERVER -u db2fenc1 db2inst1


DBI1446I  The db2icrt command is running.


DB2 installation is being initialized.

 Total number of tasks to be performed: 4 
Total estimated time for all tasks to be performed: 309 second(s) 

Task #1 start
Description: Setting default global profile registry variables 
Estimated time 1 second(s) 
Task #1 end 

Task #2 start
Description: Initializing instance list 
Estimated time 5 second(s) 
Task #2 end 

Task #3 start
Description: Configuring DB2 instances 
Estimated time 300 second(s) 
Task #3 end 

Task #4 start
Description: Updating global profile registry 
Estimated time 3 second(s) 
Task #4 end 

The execution completed successfully.

For more information see the DB2 installation log at "/tmp/db2icrt.log.2059".
DBI1070I  Program db2icrt completed successfully.

So YAY!

IBM Cloud Private - My personal success ...

I've spent much of the past few days attempting to get IBM Cloud Private (ICP) 2.1.0 deployed onto my own set of Linux VMs.

This follows on from an internal enablement session last week, where I was able to get ICP up and running without huge problems.

So this time around, I created three VMs ( one for the boot/master/management node, one for a worker node and one for the proxy node ), which is probably a minimally viable configuration ( one would typically have 2-3 worker nodes, for scalability ).

I downloaded the latest Ubuntu Linux ( 17.10 aka Artful ), and then installed the latest version of Docker CE17.11.0-ce ).

Having followed the installation guide ( well, an edited version from the enablement ), I was disappointed to find that the installation failed with: -


At the suggestion of a friend, I checked my /etc/hosts file: -


and the ICP cluster hosts file: -


I'd previously ensured that I had sufficient disk ( 150 GB per VM ) and RAM ( 8 GB per VM ).

Overnight, I had an inspiration … and checked the System Requirements pages: -



Note that Ubuntu 17.10 is NOT listed.


For all supported operating systems, Docker Enterprise Edition and Docker Community Edition versions 1.12 to 1.13.1 are supported. Docker Community Edition versions 17.03, 17.05, and 17.06 and Docker Enterprise Edition version 17.03 are also supported.

Note that Docker 17.11 is NOT listed.

Once I switched to supported versions of Ubuntu: -

lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.3 LTS
Release: 16.04
Codename: xenial


and a lower version of Docker: -

docker version

Client:
 Version:      17.09.0-ce
 API version:  1.32
 Go version:   go1.8.3
 Git commit:   afdb6d4
 Built:        Tue Sep 26 22:42:18 2017
 OS/Arch:      linux/amd64

Server:
 Version:      17.09.0-ce
 API version:  1.32 (minimum version 1.12)
 Go version:   go1.8.3
 Git commit:   afdb6d4
 Built:        Tue Sep 26 22:40:56 2017
 OS/Arch:      linux/amd64
 Experimental: false


things just worked: -


Thursday 23 November 2017

"com.ibm.bpm.config.util.ConfigException: Failed to import LTPA:" seen when attempting to move a BPM Deployment Environment from one host to another

I saw this exception: -

[23/11/17 11:57:38:222 GMT] 00000001 BPMConfig     E com.ibm.bpm.config.BPMConfig main Failed to import LTPA:
                                 com.ibm.bpm.config.util.ConfigException: Failed to import LTPA:
        at com.ibm.bpm.config.util.ws.update.UpdateLTPAKeys.importLTPA(UpdateLTPAKeys.java:170)
        at com.ibm.bpm.config.util.ws.update.UpdateLTPAKeys.updateSecurityParameters(UpdateLTPAKeys.java:73)
        at com.ibm.bpm.config.util.ws.update.ConfigPostUpdater.postUpdate(ConfigPostUpdater.java:72)
        at com.ibm.bpm.config.BPMConfig.configureDeploymentEnvironment(BPMConfig.java:835)
        at com.ibm.bpm.config.BPMConfig$Actions.createDe(BPMConfig.java:4444)
        at com.ibm.bpm.config.cli.CreateAction.runInner(CreateAction.java:156)
        at com.ibm.bpm.config.cli.AbstractConfigAction.run(AbstractConfigAction.java:129)
        at com.ibm.bpm.config.cli.CreateAction.run(CreateAction.java:35)
        at com.ibm.bpm.config.BPMConfig.main(BPMConfig.java:299)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
        at java.lang.reflect.Method.invoke(Method.java:508)
        at com.ibm.wsspi.bootstrap.WSLauncher.launchMain(WSLauncher.java:234)
        at com.ibm.wsspi.bootstrap.WSLauncher.main(WSLauncher.java:96)
        at com.ibm.wsspi.bootstrap.WSLauncher.run(WSLauncher.java:77)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
        at java.lang.reflect.Method.invoke(Method.java:508)
        at org.eclipse.equinox.internal.app.EclipseAppContainer.callMethodWithException(EclipseAppContainer.java:587)
        at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:198)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
        at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
        at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
        at java.lang.reflect.Method.invoke(Method.java:508)
        at org.eclipse.core.launcher.Main.invokeFramework(Main.java:340)
        at org.eclipse.core.launcher.Main.basicRun(Main.java:282)
        at org.eclipse.core.launcher.Main.run(Main.java:981)
        at com.ibm.wsspi.bootstrap.WSPreLauncher.launchEclipse(WSPreLauncher.java:406)
        at com.ibm.wsspi.bootstrap.WSPreLauncher.main(WSPreLauncher.java:169)
Caused by: java.io.FileNotFoundException: /home/wasadmin/ltpa.jceks (No such file or directory)
        at java.io.FileInputStream.open0(Native Method)
        at java.io.FileInputStream.open(FileInputStream.java:212)
        at java.io.FileInputStream.<init>(FileInputStream.java:152)
        at com.ibm.bpm.config.util.ws.update.UpdateLTPAKeys.importLTPA(UpdateLTPAKeys.java:119)
        ... 34 more

[23/11/17 11:57:38:229 GMT] 00000001 Ffdc          I com.ibm.ffdc.util.provider.FfdcOnDirProvider logIncident FFDC1003I: FFDC Incident emitted on /opt/ibm/WebSphere/AppServer/logs/config/ffdc_20171123-114355/ffdc.6106113977348147943.txt com.ibm.bpm.config.BPMConfig.main 163
[23/11/17 11:57:38:230 GMT] 00000001 BPMConfig     E com.ibm.bpm.config.BPMConfig main Failed to import LTPA:
[23/11/17 11:57:38:230 GMT] 00000001 SoeFactory    > com.ibm.bpm.config.soe.SoeFactory currentOs ENTRY
[23/11/17 11:57:38:230 GMT] 00000001 SoeFactory    > com.ibm.bpm.config.soe.SoeFactory getOsByType ENTRY Unix
[23/11/17 11:57:38:230 GMT] 00000001 SoeFactory    < com.ibm.bpm.config.soe.SoeFactory getOsByType RETURN Unix
[23/11/17 11:57:38:230 GMT] 00000001 SoeFactory    < com.ibm.bpm.config.soe.SoeFactory currentOs RETURN Unix
[23/11/17 11:57:38:230 GMT] 00000001 BPMConfig     I com.ibm.bpm.config.BPMConfig main The 'BPMConfig.sh -create -de /home/wasadmin/De1.properties' command failed. For more information, see the log file /opt/ibm/WebSphere/AppServer/logs/config/BPMConfig_20171123-114355.log.

whilst trying to move an IBM BPM Deployment Environment from one host to another.

The TL;DR; is that I'm running through a BPM 8.5.5 to 8.6 side-by-side migration, aiming to lift and shift the configuration from one box ( running 8.5.5 ) to another box ( running 8.6 ).

Having exported the 8.5.5 Deployment Environment: -

/opt/ibm/WebSphere/AppServer/bin/BPMConfig.sh -export -profile Dmgr01 -de De1 -outputDir  /mnt/BPM855.response

modified the resulting De1.properties file to reflect the new hostname: -

sed -i 's/bpm855/bpm86/g' De1.properties

I then attempted to create a new Deployment Environment on the box with the 8.6 binaries installed: -

/opt/ibm/WebSphere/AppServer/bin/BPMConfig.sh -create -de ~/De1.properties

This failed alas.

However, the message is clear: -

Caused by: java.io.FileNotFoundException: /home/wasadmin/ltpa.jceks (No such file or directory)

When I did the original export, I did get a bunch o' files: -

-rw-r--r-- 1 501 games  7540 Nov 23 11:38 Application-config-bpc.xml
-rw-r--r-- 1 501 games 76228 Nov 23 11:38 De1.properties
-rw-r--r-- 1 501 games  1639 Nov 23 11:38 fileRegistry.xml
-rw-r--r-- 1 501 games  1613 Nov 23 11:38 ltpa.jceks
-rw-r--r-- 1 501 games 13782 Nov 23 11:38 resources-bpc.xml


To validate the hypothesis, I cleaned up ( this on the "new" 8.6 environment ): -

/opt/ibm/WebSphere/AppServer/bin/manageprofiles.sh -deleteAll

rm -Rf /opt/ibm/WebSphereProfiles/

and then copied the ltpa.jceks to the same directory as the De1.properties file: -

cp /mnt/BPM855.response/ltpa.jceks ~

and tried again: -

/opt/ibm/WebSphere/AppServer/bin/BPMConfig.sh -create -de ~/De1.properties

which again failed: -

CWMCB2118E: No source fileRegistry.xml is found in path /home/wasadmin
The 'BPMConfig.sh -create -de /home/wasadmin/De1.properties' command failed. For more information, see the log file /opt/ibm/WebSphere/AppServer/logs/config/BPMConfig_20171123-125129.log.


Again, this makes sense, and that's easy to fix: -

cp /mnt/BPM855.response/fileRegistry.xml .

This time around ….

The 'BPMConfig.sh -create -de /home/wasadmin/De1.properties' command completed successfully.

Yay !

The moral of the story ? Make sure you have ALL the right files in ALL the right places !

For reference, here's the source for the Export process: -



Wednesday 22 November 2017

Interesting - java.lang.NoClassDefFoundError: com.ibm.xylem.utils.ErrorHandlerProvider

During an installation of IBM BPM Advanced 8.5.5 onto Red Hat Enterprise Linux 7.4 ( which, I know, is an unsupported combination ), I had an interesting experience.

This was the installation command: -

/opt/ibm/InstallationManager/eclipse/tools/imcl -input /mnt/ResponseFiles/installBPM855.rsp -acceptLicense

and this was the result: -

ERROR: java.lang.NoClassDefFoundError: com.ibm.xylem.utils.ErrorHandlerProvider

java.lang.NoClassDefFoundError: com.ibm.xylem.utils.ErrorHandlerProvider

com.ibm.oti.vm.VM.findClassOrNull(Native Method)
com.ibm.oti.vm.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:62)
com.ibm.oti.vm.VM.findClassOrNull(Native Method)
com.ibm.oti.vm.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:62)
com.ibm.xtq.xslt.jaxp.TransformerImpl.<init>(Unknown Source)
com.ibm.xtq.xslt.jaxp.TransformerImpl.<init>(Unknown Source)
com.ibm.xtq.xslt.jaxp.AbstractTransformerFactory.newTransformer(Unknown Source)
com.ibm.ws.persist.installregistries.PostSessionAction.saveDocument(PostSessionAction.java:496)
com.ibm.ws.persist.installregistries.PostSessionAction.syncFile(PostSessionAction.java:300)
com.ibm.ws.persist.installregistries.PostSessionAction.persistData(PostSessionAction.java:238)
com.ibm.ws.persist.installregistries.PostSessionAction.runPostInstall(PostSessionAction.java:161)
com.ibm.cic.agent.core.PostSessionManager.runActions(PostSessionManager.java:288)
com.ibm.cic.agent.core.PostSessionManager.runPostInstallActions(PostSessionManager.java:260)
com.ibm.cic.agent.core.PostSessionManager.run(PostSessionManager.java:113)
com.ibm.cic.agent.internal.core.Director.install(Director.java:661)
com.ibm.cic.agent.core.Agent.install(Agent.java:1796)
com.ibm.cic.agent.core.Agent.install(Agent.java:1737)
com.ibm.cic.agent.core.internal.commands.InstallCommand.execute(InstallCommand.java:244)
com.ibm.cic.agent.core.internal.commands.AbstractInstallCommand.execute(AbstractInstallCommand.java:336)
com.ibm.cic.agent.core.internal.commands.Input.executeCommands(Input.java:358)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:599)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:482)
com.ibm.cic.agent.core.application.HeadlessApplication.runAndReport(HeadlessApplication.java:492)
com.ibm.cic.agent.core.application.HeadlessApplication.runAgentNoStdout(HeadlessApplication.java:446)
com.ibm.cic.agent.core.application.HeadlessApplication.runAgent(HeadlessApplication.java:194)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:151)
com.ibm.cic.agent.core.application.HeadlessApplication.runHeadlessApplication(HeadlessApplication.java:178)
com.ibm.cic.agent.internal.ui.AgentUIApplication.launch(AgentUIApplication.java:180)
com.ibm.cic.agent.internal.ui.AgentUIApplication.start(AgentUIApplication.java:83)
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
java.lang.reflect.Method.invoke(Method.java:611)
org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
org.eclipse.equinox.launcher.Main.run(Main.java:1438)
org.eclipse.equinox.launcher.Main.main(Main.java:1414)


Interestingly, IBM Installation Manager reckoned that things were installed: -

/opt/ibm/InstallationManager/eclipse/tools/imcl listInstalledPackages

com.ibm.cic.agent_1.7.2000.20140227_0303
com.ibm.bpm.ADV.v85_8.5.5000.20140604_1130
com.ibm.websphere.ND.v85_8.5.5002.20140408_1947


and yet: -

/opt/ibm/WebSphere/AppServer/bin/versionInfo.sh 

returned: -

WVER0010I: Copyright (c) IBM Corporation 2002, 2012; All rights reserved.
WVER0012I: VersionInfo reporter version 1.15.1.48, dated 2/8/12

[Fatal Error] :-1:-1: Premature end of file.
[Fatal Error] :-1:-1: Premature end of file.
[Fatal Error] :-1:-1: Premature end of file.
[Fatal Error] :-1:-1: Premature end of file.
[Fatal Error] :-1:-1: Premature end of file.
--------------------------------------------------------------------------------
IBM WebSphere Product Installation Status Report
--------------------------------------------------------------------------------

Report at date and time 22 November 2017 20:49:02 GMT

Installation
--------------------------------------------------------------------------------
Product Directory        /opt/ibm/WebSphere/AppServer
Version Directory        /opt/ibm/WebSphere/AppServer/properties/version
DTD Directory            /opt/ibm/WebSphere/AppServer/properties/version/dtd
Log Directory            

Product List
--------------------------------------------------------------------------------
BPMPC                    installed
ND                       installed

Installed Product
--------------------------------------------------------------------------------
Premature end of file.


I uninstalled WAS and BPM: -

/opt/ibm/InstallationManager/eclipse/tools/imcl uninstallAll

Uninstalled com.ibm.bpm.ADV.v85_8.5.5000.20140604_1130 from the /opt/ibm/WebSphere/AppServer directory.
Uninstalled com.ibm.websphere.ND.v85_8.5.5002.20140408_1947 from the /opt/ibm/WebSphere/AppServer directory.

cleared down the /opt/ibm/WebSphere directory: -

rm -Rf /opt/ibm/WebSphere

and tried again: -

/opt/ibm/InstallationManager/eclipse/tools/imcl -input /mnt/ResponseFiles/installBPM855.rsp -acceptLicense

ERROR: java.lang.NoClassDefFoundError: com.ibm.xylem.utils.ErrorHandlerProvider

java.lang.NoClassDefFoundError: com.ibm.xylem.utils.ErrorHandlerProvider

com.ibm.oti.vm.VM.findClassOrNull(Native Method)
com.ibm.oti.vm.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:62)
com.ibm.oti.vm.VM.findClassOrNull(Native Method)
com.ibm.oti.vm.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:62)
com.ibm.xtq.xslt.jaxp.TransformerImpl.<init>(Unknown Source)
com.ibm.xtq.xslt.jaxp.TransformerImpl.<init>(Unknown Source)
com.ibm.xtq.xslt.jaxp.AbstractTransformerFactory.newTransformer(Unknown Source)
com.ibm.ws.persist.installregistries.PostSessionAction.saveDocument(PostSessionAction.java:496)
com.ibm.ws.persist.installregistries.PostSessionAction.syncFile(PostSessionAction.java:300)
com.ibm.ws.persist.installregistries.PostSessionAction.persistData(PostSessionAction.java:238)
com.ibm.ws.persist.installregistries.PostSessionAction.runPostInstall(PostSessionAction.java:161)
com.ibm.cic.agent.core.PostSessionManager.runActions(PostSessionManager.java:288)
com.ibm.cic.agent.core.PostSessionManager.runPostInstallActions(PostSessionManager.java:260)
com.ibm.cic.agent.core.PostSessionManager.run(PostSessionManager.java:113)
com.ibm.cic.agent.internal.core.Director.install(Director.java:661)
com.ibm.cic.agent.core.Agent.install(Agent.java:1796)
com.ibm.cic.agent.core.Agent.install(Agent.java:1737)
com.ibm.cic.agent.core.internal.commands.InstallCommand.execute(InstallCommand.java:244)
com.ibm.cic.agent.core.internal.commands.AbstractInstallCommand.execute(AbstractInstallCommand.java:336)
com.ibm.cic.agent.core.internal.commands.Input.executeCommands(Input.java:358)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:599)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:482)
com.ibm.cic.agent.core.application.HeadlessApplication.runAndReport(HeadlessApplication.java:492)
com.ibm.cic.agent.core.application.HeadlessApplication.runAgentNoStdout(HeadlessApplication.java:446)
com.ibm.cic.agent.core.application.HeadlessApplication.runAgent(HeadlessApplication.java:194)
com.ibm.cic.agent.core.application.HeadlessApplication.run(HeadlessApplication.java:151)
com.ibm.cic.agent.core.application.HeadlessApplication.runHeadlessApplication(HeadlessApplication.java:178)
com.ibm.cic.agent.internal.ui.AgentUIApplication.launch(AgentUIApplication.java:180)
com.ibm.cic.agent.internal.ui.AgentUIApplication.start(AgentUIApplication.java:83)
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
java.lang.reflect.Method.invoke(Method.java:611)
org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
org.eclipse.equinox.launcher.Main.run(Main.java:1438)
org.eclipse.equinox.launcher.Main.main(Main.java:1414)


Which is weird :-(

So that may be tomorrow's challenge - either to persist, or to switch to a supported version of RHEL.

What fun !

*UPDATE* Solved it !

Having previously used IBM Installation Manager 1.7.2 ( which comes with BPM 8.5.5 which shipped in mid-2014 ), I switched up to IBM Installation Manager 1.8.6.1.

Having done this, the installation completed successfully: -

/opt/ibm/InstallationManager/eclipse/tools/imcl -input /mnt/ResponseFiles/installBPM855.rsp -acceptLicense

Installed com.ibm.bpm.ADV.v85_8.5.5000.20140604_1130 to the /opt/ibm/WebSphere/AppServer directory.
Installed com.ibm.websphere.ND.v85_8.5.5002.20140408_1947 to the /opt/ibm/WebSphere/AppServer directory.
WARNING: A supported operating system was not detected. Support for your operating system might have been added after the release of the product. See the detailed system requirements Web pages http://www.ibm.com/support/docview.wss?uid=swg27023005 for more information about supported operating systems. You can continue with the installation, but the installation or product operation might not succeed without applying maintenance. Go to the product support Web pages http://www.ibm.com/support/docview.wss?uid=swg27006649 to obtain the latest maintenance packages to apply after installation.
WARNING: A supported operating system was not detected. Support for your operating system might have been added after the release of the product. See the WebSphere Application Server detailed system requirements Web pages - http://www.ibm.com/support/docview.wss?rs=180&&uid=swg27006921 for more information about supported operating systems. You can continue with the installation, but the installation or product operation might not succeed without applying maintenance. Go to the product support Web pages - http://www.ibm.com/support/docview.wss?rs=180&&uid=swg27004980 to obtain the latest maintenance packages to apply after installation.

Note the warning about an unsupported operating system - this comes from WebSphere Application Server 8.5.5.2, which again ships with BPM 8.5.5.

Similarly, versionInfo.sh worked: -

/opt/ibm/WebSphere/AppServer/bin/versionInfo.sh 
WVER0010I: Copyright (c) IBM Corporation 2002, 2012; All rights reserved.
WVER0012I: VersionInfo reporter version 1.15.1.48, dated 2/8/12

--------------------------------------------------------------------------------
IBM WebSphere Product Installation Status Report
--------------------------------------------------------------------------------

Report at date and time 23 November 2017 08:16:54 GMT

Installation
--------------------------------------------------------------------------------
Product Directory        /opt/ibm/WebSphere/AppServer
Version Directory        /opt/ibm/WebSphere/AppServer/properties/version
DTD Directory            /opt/ibm/WebSphere/AppServer/properties/version/dtd
Log Directory            /home/wasadmin/var/ibm/InstallationManager/logs

Product List
--------------------------------------------------------------------------------
BPMPC                    installed
ND                       installed

Installed Product
--------------------------------------------------------------------------------
Name                  IBM Business Process Manager Advanced
Version               8.5.5.0
ID                    BPMPC
Build Level           20140604-091948
Build Date            6/4/14
Package               com.ibm.bpm.ADV.v85_8.5.5000.20140604_1130
Architecture          x86-64 (64 bit)
Installed Features    Business Process Manager Advanced Process Server Non-production License

Installed Product
--------------------------------------------------------------------------------
Name                  IBM WebSphere Application Server Network Deployment
Version               8.5.5.2
ID                    ND
Build Level           cf021414.01
Build Date            4/8/14
Package               com.ibm.websphere.ND.v85_8.5.5002.20140408_1947
Architecture          x86-64 (64 bit)
Installed Features    IBM 64-bit WebSphere SDK for Java
                      WebSphere Application Server Full Profile
                      EJBDeploy tool for pre-EJB 3.0 modules
                      Embeddable EJB container
                      Stand-alone thin clients and resource adapters

--------------------------------------------------------------------------------
End Installation Status Report
--------------------------------------------------------------------------------

which is nice.

Bottom line, DON'T PANIC

IBM Cloud Private and Kubernetes - Coping files

Whilst I have used docker cp numerous times to copy files from a running container to the host ( or vice versa ), I had the need to do the same with a container running in a Pod orchestrated by Kubernetes.

The syntax for Docker is: -

docker cp <<container ID>>:/from-path /to-path

e.g.

docker cp 97ee4c182ece:/opt/ibm/db2/V11.1/java/db2jcc4.jar .

For containers running in Pods via Kubernetes, it's a little different.

The first trick is to inspect the Pod: -

kubectl get pod

NAME                                         READY     STATUS                          RESTARTS   AGE
db2trader-ibm-db2oltp-dev-2298094317-fgn0b   1/1       Running                         0          3h
jenkins-jenkins-662520783-jq60z              1/1       Running                         0          18h
loyalty-level-2196446665-hnsnv               1/1       Running                         0          12m
mqtraader-ibm-mqadvanced-0                   1/1       Running                         0          2h
notification-3317998672-qsgvj                0/1       secrets "openwhisk" not found   0          11m
portfolio-1784192597-588s1                   1/1       Running                         0          11m
redistrader-redis-0                          1/1       Running                         0          2h
redistrader-redis-1                          1/1       Running                         0          2h
redistrader-redis-2                          1/1       Running                         0          2h
stock-quote-2259670618-z0400                 1/1       Running                         0          11m
trader-2151312948-zfvch                      1/1       Running                         0          12m


kubectl describe pod mqtraader-ibm-mqadvanced-0

Name:           mqtraader-ibm-mqadvanced-0
Namespace:      default
Node:           10.0.0.3/10.0.0.3
Start Time:     Wed, 22 Nov 2017 03:07:48 -0800
Labels:         QM_IDENTIFIER=mqtraader
                app=mqtraader-ibm-mqadvanced
                chart=ibm-mqadvanced-server-dev-1.0.1
                controller-revision-hash=mqtraader-ibm-mqadvanced-1107708458
                heritage=Tiller
                release=mqtraader
Annotations:    kubernetes.io/created-by={"kind":"SerializedReference","apiVersion":"v1","reference":{"kind":"StatefulSet","namespace":"default","name":"mqtraader-ibm-mqadvanced","uid":"5f5a8bc6-cf75-11e7-82cf-005056...
                kubernetes.io/psp=default
Status:         Running
IP:             10.1.88.143
Created By:     StatefulSet/mqtraader-ibm-mqadvanced
Controlled By:  StatefulSet/mqtraader-ibm-mqadvanced
Containers:
  qmgr:
    Container ID:   docker://fe7c9127776da0bdea9953dd4d804af17318b019f68aac521222a795d06bf1a3
    Image:          ibmcom/mq:9
    Image ID:       docker-pullable://ibmcom/mq@sha256:76d74d07ccd6fa49297ba01f199ac95e0f89d8c4a068ccb655380c6a5d8aec93
    Ports:          1414/TCP, 9443/TCP
    State:          Running
      Started:      Wed, 22 Nov 2017 03:07:50 -0800
    Ready:          True
    Restart Count:  0
    Limits:
      cpu:     500m
      memory:  512Mi
    Requests:
      cpu:     500m
      memory:  512Mi
    Environment:
      LICENSE:            accept
      MQ_QMGR_NAME:       admin
      MQ_ADMIN_PASSWORD:  <set to the key 'adminPassword' in secret 'mqtraader-ibm-mqadvanced'>  Optional: false
      MQ_APP_PASSWORD:    <set to the key 'appPassword' in secret 'mqtraader-ibm-mqadvanced'>    Optional: false
    Mounts:
      /mnt/mqm from mqtraader-ibm-mqadvanced-mqvol1 (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from default-token-l601r (ro)
Conditions:
  Type           Status
  Initialized    True 
  Ready          True 
  PodScheduled   True 
Volumes:
  mqtraader-ibm-mqadvanced-mqvol1:
    Type:       PersistentVolumeClaim (a reference to a PersistentVolumeClaim in the same namespace)
    ClaimName:  mqtraader-ibm-mqadvanced-mqvol1-mqtraader-ibm-mqadvanced-0
    ReadOnly:   false
  default-token-l601r:
    Type:        Secret (a volume populated by a Secret)
    SecretName:  default-token-l601r
    Optional:    false
QoS Class:       Guaranteed
Node-Selectors:  <none>
Tolerations:     node.alpha.kubernetes.io/notReady:NoExecute for 300s
                 node.alpha.kubernetes.io/unreachable:NoExecute for 300s
Events:          <none>

grabbing the Name and the Namespace, and then using kubectl cp as per the following example: -

kubectl cp default/mqtraader-ibm-mqadvanced-0:/opt/mqm/java/lib/jca/wmq.jmsra.rar ./wmq.jmsra.rar

tar: Removing leading `/' from member names

However, notice one nuance - it's necessary to specify the destination file name as well as the destination path.

Otherwise, if you do this: -

kubectl cp default/mqtraader-ibm-mqadvanced-0:/opt/mqm/java/lib/jca/wmq.jmsra.rar .

you get this: -

tar: Removing leading `/' from member names
error: open .: is a directory


which took me a while to work around.

:-)

Tuesday 21 November 2017

IBM Java and Health Centrer - There's More

Following an earlier post: -


I've been guiding a colleague in the use of HC, outside of WebSphere Application Server (WAS).

This time I wanted to show how HC could be used to monitor a Plain Ole Java Object (POJO), specifically a Java class.

Here's one I prepared earlier: -

HelloWorld.java

public class HelloWorld
{
public static void main(String[] args)
{
while (true)
{
System.out.println("Hello, World");
}
}
}

WARNING - this will run forever, in an infinite loop, but it's good for my testing purposes.

Having setup my shell to reflect the IBM Java 8 JRE, thanks to the WAS setupCmdLine.sh script: -

source /opt/ibm/WebSphereProfiles/Dmgr01/bin/setupCmdLine.sh 

I compiled the class: -

javac HelloWorld.java 

and executed it: -

java HelloWorld

to prove that it works.

I then added HC into the mix: -

java -Xhealthcenter:transport=jrmp HelloWorld

Note that, as before, I've added :transport=jrmp into the mix, as I'm using Eclipse on macOS with Oracle's Java 8 JRE on the client-side, even though the server-side is using the IBM Java8 JRE.

I was then able to hook up Eclipse, as per the previous blog post.

One other useful tip; if I start the Java class thus: -

java -Xhealthcenter:transport=jrmp HelloWorld >> /tmp/foobar

the actual "Hello World!" message gets appended to /tmp/foobar but I see: -


in the console, allowing me to validate that HC is running and listening on port 1972.

I also validated this from another terminal: -


where 49134 is the Process ID of the running JRE: -


and then probed it: -


and: -


Job done !

Thursday 16 November 2017

IBM DB2, Red Hat Enterprise Linux and the IBM Mainframe

I'm running through the process to deploy IBM Business Process Manager (BPM) 8.6 onto an IBM mainframe ….

This is something that I've done a number of times before, since I first joined the (then) IBM Software Services for WebSphere team in late 2012.

In essence, although the underlying hardware is the IBM z platform ( also known as LinuxOne in this guise ), I'm installing BPM etc. onto Red Hat Enterprise Linux (RHEL) and Linux is …. Linux.

So the approach to install BPM, and it's dependencies, is similar to any other Linux - in the main, I work with X86-64, so I used my notes for that platform as a Starter for 10.

I did, however, hit one glitch, namely in the context of installing IBM DB2 11.1.

Whilst I was attempting to install DB2: -

/tmp/Repo/DB2/Product/server_awse_o/db2setup -r /tmp/Repo/db2server111.rsp

I saw this: -

Requirement not matched for DB2 database "Server" . Version: "11.1.0.0". 

Summary of prerequisites that are not met on the current system: 

   DBT3514W  The db2prereqcheck utility failed to find the following 32-bit library file: "/lib/libpam.so*". 


/tmp/Repo/DB2/Product/server_awse_o/db2/linux390/install/../bin/db2usrinf: error while loading shared libraries: libibmc++.so.1: cannot open shared object file: No such file or directory
/tmp/Repo/DB2/Product/server_awse_o/db2/linux390/install/../bin/db2usrinf: error while loading shared libraries: libibmc++.so.1: cannot open shared object file: No such file or directory
/tmp/Repo/DB2/Product/server_awse_o/db2/linux390/install/../bin/db2usrinf: error while loading shared libraries: libibmc++.so.1: cannot open shared object file: No such file or directory


Now the libyan.so message is common, and I've mostly ignored that - PAM == Pluggable Authentication Module and, as far as I can recollect, we'd only leverage PAM if we wanted to have DB2 users ( instance owner etc. ) authenticate against LDAP, which isn't a requirement for ME.

However, the exception re libibmc++.so.1 was more of a pain.

Thankfully, as ever, the Internet came to my rescue, with this: -




Following the advice therein, I went here: -


and downloaded the runtime from IBM Fix Central.

Having done so, I extracted the archive: -

tar xvzf IBM_XL_C_CPP_V1.2.0.0_LINUX_390_RUNTIME.tar.gz -C /tmp/Repo/CPP/

installed it: -

/tmp/Repo/CPP/install

/usr/bin/sudo rpm -Uvh /tmp/Repo/CPP/images/rhel/rpms/libxlc-1.2.0.0-151119a.s390x.rpm
Preparing...                          ################################# [100%]
Updating / installing...
   1:libxlc-1.2.0.0-151119a           ################################# [100%]

and set the LD_LIBRARY_PATH variable: -

export LD_LIBRARY_PATH=/opt/ibm/lib64

This allowed me to install DB2: -

/tmp/Repo/DB2/Product/server_awse_o/db2setup -r /tmp/Repo/db2server111.rsp

Requirement not matched for DB2 database "Server" . Version: "11.1.0.0". 

Summary of prerequisites that are not met on the current system: 

   DBT3514W  The db2prereqcheck utility failed to find the following 32-bit library file: "/lib/libpam.so*". 


DBI1191I  db2setup is installing and configuring DB2 according to the
      response file provided. Please wait.


The execution completed with warnings.

For more information see the DB2 installation log at "/tmp/db2setup.log".

However…..

When I came to patch DB2, it happened again: -

/tmp/Repo/DB2/Fixpack/universal/installFixPack -n -b /opt/ibm/db2/V11.1/

Requirement not matched for DB2 database "Server" . Version: "11.1.2.2". 

Summary of prerequisites that are not met on the current system: 

   DBT3514W  The db2prereqcheck utility failed to find the following 32-bit library file: "/lib/libpam.so*". 


/opt/ibm/db2/V11.1/bin/db2langdir: error while loading shared libraries: libibmc++.so.1: cannot open shared object file: No such file or directory
/opt/ibm/db2/V11.1/bin/db2langdir: error while loading shared libraries: libibmc++.so.1: cannot open shared object file: No such file or directory
DBI1131E  The user ID DBI1055E is invalid.

Explanation: 

An attempt to access the given user ID failed. One of the following
situations has occurred:

*  This user ID does not exist on the system.

*  The home directory of this user does not exist or is not set up
   properly.

*  One of the user attributes needed by the database manager is unset.

*  The UID of this user is 0

User response: 

Make sure a valid user ID with valid home directory, shell, primary
group and secondary group has been used. Create a new user if necessary.


   Related information:
   Creating group and user IDs for a DB2 database installation (Linux
   and UNIX)
   DB2 users and groups (Linux and UNIX)

I dug around internally (!), and found another gem; to create symbolic links to the newly installed IBM C/C++ runtime into /usr/lib.

Working on the "Hope for the best, but plan for the worst" scenario, I did this: -

ln -s /opt/ibm/lib/libibmc++.so.1 /usr/lib
ln -s /opt/ibm/lib64/libibmc++.so.1 /usr/lib64/

and was then able to install the fix pack: -

/tmp/Repo/DB2/Fixpack/universal/installFixPack -n -b /opt/ibm/db2/V11.1/

Requirement not matched for DB2 database "Server" . Version: "11.1.2.2". 

Summary of prerequisites that are not met on the current system: 

   DBT3514W  The db2prereqcheck utility failed to find the following 32-bit library file: "/lib/libpam.so*". 


DBI1017I  installFixPack is updating the database products installed in
      location /opt/ibm/db2/V11.1/.


The execution completed successfully.

For more information see the DB2 installation log at
"/tmp/installFixPack.log.62145".

So that's another fine mess, got out of :-)


Tuesday 14 November 2017

Telnet, my Telnet - Or macOS High Sierra, what have you done ?

This harks back to a VERY old post: -

which was penned back in 2010.

Since I've upgraded to macOS High Sierra, I've lost the FTP and Telnet clients.

Ordinarily that wouldn't be a problem but ….

Telnet is often useful for testing ports e.g. telnet localhost 9443.

Thankfully, we have a solution …. Netcat.


nc -vnzu 127.0.0.1 9080
found 0 associations
found 1 connections:
     1: flags=82<CONNECTED,PREFERRED>
outif (null)
src 127.0.0.1 port 59595
dst 127.0.0.1 port 9080
rank info not available

Connection to 127.0.0.1 port 9080 [udp/*] succeeded!

nc -vnzu 127.0.0.1 9443
found 0 associations
found 1 connections:
     1: flags=82<CONNECTED,PREFERRED>
outif (null)
src 127.0.0.1 port 54459
dst 127.0.0.1 port 9443
rank info not available

Connection to 127.0.0.1 port 9443 [udp/*] succeeded!

etc.

So it's a bit more fiddly !

So I hacked a solution !

alias 

alias hist='history | cut -c 8-'
alias telnet='nc -vnzu'


So now I can run: -

telnet 127.0.0.1 8443
found 0 associations
found 1 connections:
     1: flags=82<CONNECTED,PREFERRED>
outif (null)
src 127.0.0.1 port 52157
dst 127.0.0.1 port 8443
rank info not available

Connection to 127.0.0.1 port 8443 [udp/*] succeeded!

Bazinga!

Vagrant and VMware - all the Vs together - or not

Further to my last: -


I'm now looking at the options to use VMware Workstation ( this is on Linux, rather than my default home of macOS ) instead of VirtualBox.

Following this: -


I've installed the appropriate plugin: -

vagrant plugin install vagrant-vmware-workstation

Installing the 'vagrant-vmware-workstation' plugin. This can take a few minutes...
Fetching: vagrant-share-1.1.9.gem (100%)
Fetching: vagrant-vmware-workstation-5.0.3.gem (100%)
Building native extensions.  This could take a while...

Vagrant is installing the VMware plugin which requires
root access. You may be prompted for your password to
complete setup.

[sudo] password for hayd: 
Installed the plugin 'vagrant-vmware-workstation (5.0.3)'!


and validated the plugin: -

vagrant plugin list

vagrant-share (1.1.9, system)
vagrant-vmware-workstation (5.0.3)


I then updated my Vagrantfile to reflect the new choice of provider : -

vi Vagrantfile

inserting: -

...
config.vm.provider "vmware-workstation"

Finally, I tried (!) to bring my VM up: -

vagrant up

A valid license is required to run the Vagrant VMware
provider. Please visit http://www.vagrantup.com to purchase
a license. Once you purchase a license, you can install it
using `vagrant plugin license`.
Vagrant failed to initialize at a very early stage:

The plugins failed to load properly. The error message given is
shown below.

exit


Foiled again!

Then I read the Vagrant website more thoroughly



So I need to buy a license for the VMware Plugin from Vagrant ( aka Hashicorp ) at $80


Ah, well, back to VirtualBox for now …..

Visual Studio Code - Wow 🙀

Why did I not know that I can merely hit [cmd] [p]  to bring up a search box allowing me to search my project e.g. a repo cloned from GitHub...