From Fedora Project Wiki
Line 161: Line 161:
* [ Firefox Web Developer Add-on]
* [ Firefox Web Developer Add-on]

Revision as of 13:11, 26 September 2016


For all Java subsystem debugging, installing the symbols package java-1.7.0-openjdk-debuginfo is essential. All debuginfo sub-packages reside in own repository which needs to be enabled for installation at least. An example yum command:

# yum install --enablerepo=fedora-debuginfo -y java-1.7.0-openjdk-debuginfo

Fedora release > 15

Since Fedora 15, Java console has been removed from Firefox Web developer tools add-on and it hasn't existed in the browser itself for some time. Related bugs:

Background for this change was that nowdays there can be more than one JVM instance connected to a web browser and thus console feature was moved to JVM itself. Command:

# yum install --enablerepo=fedora-debuginfo -y icedtea-web

would install console support. There is also packages icedtea-web-debuginfo and icedtea-web-javadoc.

Standard Output / Standard Error Output

Firefox detected plugin list can be seen by typing the url:


Firefox can be run in debug mode as follows:

$ ICEDTEAPLUGIN_DEBUG=true firefox 2>&1 | tee console.log

This will write the standard output also to a file.

Browser plugin also writes files under user's


All these files are valuable information which can/should be attached to a bug reports.

Attaching a debugger

When running in debug mode (with ICEDTEAPLUGIN_DEBUG=true), it is also possible to attach a debugger to JVM process, thus allowing stepping through applet code and the plugin code itself.

Once the applet is loaded, just attach the debugger of your choice to port 8787, and you can then set breakpoints in the applet code.

Sometimes it may be necessary to debug the applet's init function. To to do that, first load a simple (working) applet in the browser. If you load, that should do it (the top left corner has an applet). This will start the JVM, allowing you to attach a debugger to it. Once the debugger is attached, you can set up breakpoints in the applet code and then proceed to load the applet. If you are using the NP plugin (default in Fedora 13 and higher), you need to load your applet applet in another tab. Loading it in the same tab will not work, as the VM will be shutdown as soon as the previous page closes to load the new one.

Java Console

OpenJDK does not ship the Java console anymore, but one can be found from Firefox Web Developer add-on which is installed separately to the Firefox. Add-ons are installed using Firefox's own software component management system, not Fedora's RPM.

Once Web Developer add-on has been installed, it can be activated from:

 View --> Toolbars --> Web Developer Toolbar

and that will open a new toolbar above the browser's rendering area. Java Console can be then opened from:

 Tools --> Java Console

Fedora release > 15

Console has moved to icedTea itself (requires icedtea-web package). Activating the console can be done with gui-tool:

 Program menu --> Settings --> IcedTea Web Control Panel


Console can for example list detailed information about the environment which can be useful for bugreporting:

System Properties:

http.agent: Java(tm) 2 SDK, Standard Edition v1.6.0_0 true
java.version.applet: true OpenJDK Runtime Environment
sun.boot.library.path: /usr/lib/jvm/java-1.6.0-openjdk-
java.vm.version: 14.0-b16
browser: sun.applet.AppletViewer
java.vendor.applet: true
java.vm.vendor: Sun Microsystems Inc.
path.separator: : OpenJDK 64-Bit Server VM
file.separator.applet: true US SUN_STANDARD
sun.os.patch.level: unknown
os.version.applet: true Java Virtual Machine Specification
user.dir: /home/tuju/Documents
java.runtime.version: 1.6.0_0-b16
java.awt.graphicsenv: sun.awt.X11GraphicsEnvironment
java.endorsed.dirs: /usr/lib/jvm/java-1.6.0-openjdk-
os.arch: amd64
browser.version: 1.06
javax.accessibility.assistive_technologies: org.GNOME.Accessibility.JavaBridge
line.separator: /tmp
java.vm.specification.vendor: Sun Microsystems Inc. Linux
java.class.version.applet: true
sun.jnu.encoding: UTF-8
java.library.path: /usr/lib/jvm/java-1.6.0-openjdk-
java.class.version: 50.0 Java Platform API Specification
path.separator.applet: true HotSpot 64-Bit Server Compiler
package.restrict.definition.sun: true
os.arch.applet: true
browser.vendor: Sun Microsystems Inc.
user.home: /home/tuju
user.zoneinfo.dir: /usr/share/javazi
user.timezone: Europe/Tallinn
java.awt.printerjob: sun.print.PSPrinterJob
line.separator.applet: true
java.specification.version: 1.6
file.encoding: UTF-8
java.class.path: . tuju true
java.vm.specification.version: 1.0
java.home: /usr/lib/jvm/java-1.6.0-openjdk- 64
user.language: en
java.specification.vendor: Sun Microsystems Inc. mixed mode
java.version: 1.6.0_0
java.ext.dirs: /usr/lib/jvm/java-1.6.0-openjdk-
sun.boot.class.path: /usr/lib/jvm/java-1.6.0-openjdk-
java.vendor: Sun Microsystems Inc.
file.separator: /
java.vendor.url.bug: UnicodeLittle
sun.cpu.endian: little
java.vendor.url.applet: true

Test URLs

Fedora's JRE in browser environment can be tested using the following test pages:

Note that those pages itself are sad examples of compliance of specifications: buggy or buggier - if you know any better pages, change them here.

See Also