Skip to main content
Inspiring
March 13, 2017
Question

Could not initialize class javax.media.jai.JAI - CF11

  • March 13, 2017
  • 3 replies
  • 2791 views

Hey all,

We have a bit of an odd issue on one of our Linux CentOS 7 64bit servers with ColdFusion 11 Enterprise (latest patches installed), when we use features in CFImage we get the following logged errors:

ERROR

"Error","ajp-bio-8014-exec-5","03/13/17","15:29:25",,"Could not initialize class javax.media.jai.JAI The specific sequence of files included or processed is: /home/test/public_html/test.cfm, line: 8 "

java.lang.NoClassDefFoundError: Could not initialize class javax.media.jai.JAI

  at coldfusion.image.Image.crop(Image.java:1177)

  at coldfusion.runtime.CFPage.ImageCrop(CFPage.java:7683)

SYSTEM

Server Details
Server ProductColdFusion
Version11,0,11,301867
Tomcat Version7.0.68.0
EditionEnterprise 
Operating SystemUNIX 
OS Version3.10.0-514.2.2.el7.x86_64 
Update Levelopt/coldfusion11/cfusion/lib/updates/chf11000011.jar 
Adobe Driver Version5.1.3 (Build 000094) 
JVM Details
Java Version1.8.0_121 
Java VendorOracle Corporation 
Java Vendor URLhttp://java.oracle.com/
Java Home/opt/jdk1.8.0_121/jre 

Any ideas on what could be the issue here? We have done an update on the JAVA version and also checked that all jai_core.jar/jai_codec.jar/jai_imageio.jar are present and correct.

Cheers!

This topic has been closed for replies.

3 replies

Inspiring
February 26, 2018

Same problem here!

But possibly resolved after revising Java settings

to include -XX:+UseG1GC (replacing -XX:+UseParallelGC).

And it still worked after changing back to Parallel,

but maybe more trustworthy with the G1 setting.

ColdFusion 11 Update 13

Java 1.8.0_161

Sandbox security enabled

Windows Server 2012 R2

Participating Frequently
August 17, 2018

same issue here.   CF2016 update 6  jre1.8.0_171

tried G1GC, didn't fix the problem.  

tried reverting back to c:\coldfusion2016\jre\.  didn't fix the problem 

 

happens on invoke of imageScaleToFit()

 

additionally, the exception that's thrown is uncatchable with <cfcatch type="any">

BKBK
Community Expert
March 18, 2017

Bug test: what does the following code produce

<cfset testJAIObject = createobject("java", "javax.media.jai.JAI")>

<cfdump var="#testJAIObject#">

Vikram Kumar M
Community Manager
Community Manager
March 14, 2017

Hi Jonathon,

We apologise for the inconvenience, in case if you feel this is a bug, you can log it on our bug base.

https://tracker.adobe.com/#/home

Thanks,

Vikram