Over a million developers have joined DZone.

Upgrading ColdFusion To Java 7

DZone 's Guide to

Upgrading ColdFusion To Java 7

· Performance Zone ·
Free Resource

ColdFusion 10 shipped with Java version 6 (also referred to as JRE 1.6). And until recently, ColdFusion 9 and 10 users had to use Java 6 and could not upgrade to Java 7 (JRE 1.7). But Oracle recently announced that Java 6 is no longer being updated as of the end of February 2013, which is why it was so critical for us to release updates for ColdFusion 9.x and ColdFusion 10 to provide support for JRE 1.7.

Now that ColdFusion supports Java 7, you should indeed upgrade, and (as requested by several ColdFusion users) here are some instructions and pointers.

ColdFusion ships with a Java runtime, and that's most likely what your ColdFusion server is using. To upgrade the JRE you actually leave the existing one intact (which makes it possible to easily restore to the prior state if something goes wrong). When you upgrade the Java runtime you install a new copy of Java, and then tell ColdFusion to use it instead of the one used previously.

(Obviously, make sure you have backups, and you probably don't want to make these changes during peak use time, this is definitely an off-peak type of upgrade).

Ok, here's what you need to do ...

  1. ColdFusion stores the path of its Java runtime in /cfusion/bin/jvm.config. Make a backup of this file! That way, if something goes wrong, you can simply stop ColdFusion, restore that file, restart ColdFusion, and you'll be back up and running as if you'd have changed nothing at all.
  2. Download JRE 7 on to your ColdFusion server. Make sure you pick the right version for your OS. If you are using 32bit ColdFusion you must install the 32bit JRE, and if you are using 64bit ColdFusion you must install the 64bit JRE. (Pay attention to the 32bit versus 64bit decision, on a 64bit machine the page may default to 32bit if it detects you are using a 32bit web browser).
  3. Once you have downloaded JRE 1.7, install it on your server.
  4. Note the JRE 1.7 installation folder, you'll need the full path to it.
  5. Log in to ColdFusion Administrator.
  6. Go to the Server Settings > Java and JVM page.
  7. Replace the Java Virtual Machine Path with the path to the newly installed JRE 1.7 (you can also click Browse Server to locate the folder), then click Submit Changes.
  8. You will be instructed to restart ColdFusion, so do that.
  9. Once ColdFusion has restarted, log back into the ColdFusion Administrator and go to Server Settings > Settings Summary. In the JVM Details section Java Version should indicate that you are running 1.7.0_15 (or newer).

That's all there is to it! Obviously, you should test that your sites and apps are all working properly. And as noted previously, if something is not working, you can always stop ColdFusion, restore the jvm.config file, and then restart, to return ColdFusion back to its pre-upgraded state.


Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}