IBM Support

Java exception - java.lang.IllegalArgumentException: Width (0) and height (0) cannot be <= 0 thrown when executing launcheradmin.sh, mgmtconsole.sh, or resourceregistry.sh on Linux

Troubleshooting


Problem

On some Linux® machines, when you run the WebSphere® Transformation Extender Launcher Administration, Management Console, and Resource Registry tools, they might fail to start with the the following Java® exception: java.lang.IllegalArgumentException: Width (0) and height (0) cannot be <= 0.

Symptom

The Java stack trace for the error might contain the following exception details:

Exception in thread "main" java.lang.IllegalArgumentException: Width (0) and height (0) cannot be <= 0
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:1031)
at sun.awt.X11.XFramePeer.setIconImage(XFramePeer.java:245)
at sun.awt.X11.XFramePeer.postInit(XFramePeer.java:103)
at sun.awt.X11.XBaseWindow.init(XBaseWindow.java:146)
at sun.awt.X11.XBaseWindow.<init>(XBaseWindow.java:179)
at sun.awt.X11.XWindow.<init>(XWindow.java:112)
at sun.awt.X11.XComponentPeer.<init>(XComponentPeer.java:128)
at sun.awt.X11.XPanelPeer.<init>(XPanelPeer.java:55)
at sun.awt.X11.XWindowPeer.<init>(XWindowPeer.java:77)
at sun.awt.X11.XDecoratedPeer.<init>(XDecoratedPeer.java:64)
at sun.awt.X11.XFramePeer.<init>(XFramePeer.java:69)
at sun.awt.X11.XToolkit.createFrame(XToolkit.java:380)
at java.awt.Frame.addNotify(Frame.java:524)
at java.awt.Window.show(Window.java:539)
at java.awt.Component.show(Component.java:1337)
at java.awt.Component.setVisible(Component.java:1290)
at com.ibm.websphere.dtx.launcher.gui.EventServerAdmin.<init>(Unknown Source)
at com.ibm.websphere.dtx.launcher.gui.EventServerAdmin.main(Unknown Source)

Cause

The Sun AWT (Abstract Window Toolkit) class

Resolving The Problem

Sun® Microsystems, Inc. has re-implemented Sun AWT as documented in the "XToolkit on Solaris/Linux" tech note that is located on the following Web page:

http://java.sun.com/javase/6/docs/technotes/guides/awt/1.5/xawt.html

The tech note starts with the following announcement about the new
XToolkit implementation:
“Starting with release J2SETM 5.0, AWT has been re-implemented on the Solaris and Linux platforms." It explains the advantages of implementing
the new Toolkit, and continues with the following statement about the
default Toolkit version on Linux in J2SE 5.0:
“The new Toolkit (XToolkit) is the default on Linux in J2SE 5.0.”

To resolve the java.lang.IllegalArgumentException exception on Linux, set
the following environment variable before you run the WebSphere Transformation
Extender Management Tools:

export AWT_TOOLKIT=MToolkit

When you run the WebSphere Transformation Extender Launcher Administration, Management Console, and Resource Registry tools, they
should now start successfully and not throw the Java exception.

[{"Product":{"code":"SSVSD8","label":"IBM Transformation Extender"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Launcher Administration","Platform":[{"code":"PF016","label":"Linux"}],"Version":"8.2.0.4;8.2.0.3;8.2.0.2;8.2.0.1;8.2","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Product Synonym

WTX Mercator DSTX DTX

Document Information

Modified date:
16 June 2018

UID

swg21398324