IBM Rational Application Developer, Integration Designer, InfoSphere Data Architect, Rational Team Concert, etc. fails to start/work on Centos, Fedora or RHEL with Java exit code 160? Probably this will help…

It is very popular nowdays to use XUL from Eclipse based products, and IBM product use this “pattern” a lot. The problem is that RHEL6 and Centos 6 comes with Firefox 3.6; unfortunately, after some months Firefox gets upgraded to some newer version and as result XUL library also gets upgraded to some newer version… which is INCOMPATIBLE with IBM products, which relies on the original “vanilla” library. I have already wrote about this problem. But since then something has changed: first of all — problem is no longer a problem of just Fedora, it may arise on RHEL and Centos as well, secondly the distributive of Firefox 3.6 is no longer available on (there is a download page, but nothing under the links, except HTTP 404), so I uploaded 3.6.19 (that I had in my archives) to RapidShare.


Firstly, download Firefox 3.6.19 from there. Next, install it under /usr/lib/firefox-3.6.19. And next modify launcher for your IBM product (in my case it is Rational Software Architect 8.0.3):
/home/alex/IBM/SDP/eclipse -product
/home/alex/IBM/SDP/eclipse -product -vmargs -Dorg.eclipse.swt.browser.XULRunnerPath=/usr/lib/firefox-3.6.19/


if you may modify eclipse.ini file for the product, for example for IBM Integration Designer:

edit file /home/alex/IBM/IntegrationDesigner/v8.0/eclipse.ini and add one line in the very end:


That is it, it works.

Make Rational Team Concert Client Work on Fedora 15

Problem description

Fedora 15 has Firefox 5 on board and thus some latest XUL runner (on my machine today it is xulrunner-5.0-2.fc15.i686), Rational Team Concert ignores Fedora presence (it supports whatever, including RHEL, but not our lovely cutting-edge distro). That is why it does not simply run on Fedora 15 (it expects xulrunner to be at the same level as in RHEL). There is an example of what happens. (In short: visual indication of the problem is abnormal termination of Rational product when you open Jazz Administration or other Jazz related perspective, in case of standalone RTC client it will be right after startup, in case of RAD or RSA when you switch to the perspective manually).

In fact you may try downgrade XUL but I would never recommend it, since it is very error prone way, especially for YUM-driven Fedora.


Firstly, I downloaded Firefox 3.6.19 from there (or from here, since 3.6 may be no longer available from Firefox site). Next, I installed it under /usr/lib/firefox-3.6.19. And next I modified launcher for you Rational product (in my case it is Rational Software Architect 8.0.3):
/home/alex/IBM/SDP/eclipse -product
/home/alex/IBM/SDP/eclipse -product -vmargs -Dorg.eclipse.swt.browser.XULRunnerPath=/usr/lib/firefox-3.6.19/

That is it, it works.
NOTE:This solution will help if before you successfully fix the SELinux problem for JRE bundled into Rational product(s), because SELinux arises at earlier stages of Eclipse loading.

How to override default OpenJDK in Fedora with SUN/Oracle JDK

I always did it pretty straight, I installed SUN JDK, I put-in SUN’s “java” executable into PATH variable, “export JAVA_HOME”, I did it usually in some “*.sh” file in to “/etc/profile.d”, and well actually it is not a good place for it. However, Fedora manages mapping between “java” link and real target executable via system of symbolic links (managed via “alternatives” utility). Alas, SUN’s JDK does not “invoke alternatives” to declare its alternatives.
But today I had a time to solve this problem as it must have been solved:
Meet “”:

JAVA_HOME=`readlink -f "$JAVA_HOME"`
if [ -n "$2" ]; then
alternatives --verbose --install /usr/bin/java java "${JAVA_HOME}/bin/java" ${PRIORITY} \
	--slave /usr/bin/javaws javaws "${JAVA_HOME}/bin/javaws" \
	--slave /usr/bin/keytool keytool "${JAVA_HOME}/bin/keytool" \
	--slave /usr/bin/orbd orbd "${JAVA_HOME}/bin/orbd" \
	--slave /usr/bin/pack200 pack200 "${JAVA_HOME}/bin/pack200" \
	--slave /usr/bin/rmid rmid "${JAVA_HOME}/bin/rmid" \
	--slave /usr/bin/rmiregistry rmiregistry "${JAVA_HOME}/bin/rmiregistry" \
	--slave /usr/bin/servertool servertool "${JAVA_HOME}/bin/servertool" \
	--slave /usr/bin/tnameserv orbd "${JAVA_HOME}/bin/tnameserv" \
	--slave /usr/bin/unpack200 unpack200 "${JAVA_HOME}/bin/unpack200" \
	--slave /usr/lib/jvm-exports/jre jre_exports "${JAVA_HOME}/jre" \
	--slave /usr/lib/jvm/jre jre "${JAVA_HOME}/jre" \
	--slave /usr/share/man/man1/java.1 java.1 "${JAVA_HOME}/man/man1/java.1" \
	--slave /usr/share/man/man1/javaws.1 javaws.1 "${JAVA_HOME}/man/man1/javaws.1" \
	--slave /usr/share/man/man1/keytool.1 keytool.1 "${JAVA_HOME}/man/man1/keytool.1" \
	--slave /usr/share/man/man1/orbd.1 orbd.1 "${JAVA_HOME}/man/man1/orbd.1" \
	--slave /usr/share/man/man1/pack200.1 pack200.1 "${JAVA_HOME}/man/man1/pack200.1" \
	--slave /usr/share/man/man1/rmid.1 rmid.1 "${JAVA_HOME}/man/man1/rmid.1" \
	--slave /usr/share/man/man1/rmiregistry.1 rmiregistry.1 "${JAVA_HOME}/man/man1/rmiregistry.1" \
	--slave /usr/share/man/man1/servertool.1 servertool.1 "${JAVA_HOME}/man/man1/servertool.1" \
	--slave /usr/share/man/man1/tnameserv.1 tnameserv.1 "${JAVA_HOME}/man/man1/tnameserv.1" \
	--slave /usr/share/man/man1/unpack200.1 unpack200.1 "${JAVA_HOME}/man/man1/unpack200.1"

Run it under root:

./ /usr/java/latest

NOTE: /usr/java/latest is what would be JAVA_HOME if you selected “classical” approach.
And now you may run (again as root):

# alternatives --config java

There are 2 programs which provide 'java'.

  Selection    Command
*+ 1           /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
   2           /usr/java/latest/bin/java

Enter to keep the current selection[+], or type selection number: 

Select 2 and it will result in:

# java -version
java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) Server VM (build 20.1-b02, mixed mode)

If you rerun alternatives --config java and select 1 you will return to the previous configuration:

# java -version
java version "1.6.0_20"
OpenJDK Runtime Environment (IcedTea6 1.9.7) (fedora-
OpenJDK Server VM (build 19.0-b09, mixed mode)

The advantage is that such a toggle is immediate, you should not relogin to force files from profile.d to run.