How to change/upgrade JDK version of ColdFusion server

In this blog, we will discuss how to upgrade the latest minor version of JDK(Java Development Kit) of the ColdFusion server. ColdFusion can run only on top of JDK or JRE with Server VM. Oracle also started providing separate download links for JRE and Server JRE. ColdFusion only works with JDK or Server JRE and not with Client JRE [For more details refer article].
 
ColdFusion 10 and 11 can be installed in two modes:
  • Standalone installation
  • Deployment on JEE servers (IBM Websphere, Oracle Weblogic, JBoss etc.)
If ColdFusion server is deployed on any JEE application server, then documentation for respective application server should be followed in order to change the JDK of the underlying application server.
In standalone installation, there are two ways to change the JDK or Server JRE of ColdFusion server:
 
  1. Using ColdFusion administrator console.
  2. By changing the JDK or Server JRE path from the jvm.config file.
 
1. Using ColdFusion administrator console.
 
  • Download the latest minor version of the supported JDK or Server JRE.
  • Install the JDK or Server JRE.
  • Navigate to ColdFusion Administrator > Server Settings > Java and JVM section.
  • Browse the path to the JDK or Server JRE from the “Java Virtual Machine Path” textbox which you intended to use with ColdFusion.
  • Click “Submit Changes”.
  • Restart the ColdFusion Application service.
 
 
2. By changing the JDK or Server JRE path from the jvm.config file
  • Download the latest minor version of the supported JDK or Server JRE.
  • Install the JDK or Server JRE.
  • Open jvm.config file located at <cf_install_root>\cfusion\bin.
  • Change the value of java.home to the JDK or Server JRE path. [For example: C:\\Program Files\\Java\\jdk1.7.0_25\\jre or C:/Program Files/Java/jdk1.7.0_25/jre]
  • Save the changes to the jvm.config file.
  • Restart the ColdFusion Application service.

 

Important Note:
  • It is not recommended to change the JDK version on the production servers without any prior testing in the staging environment.
  • Any SSL certificates added to the previous JDK will also need to be re-added to the new JDK(cacerts) file.
  • JDK or Server JRE location used, should be correct, otherwise ColdFusion server will not start.
    • If JDK is being used, then path should point till JRE directory available inside JDK home directory. For example, JDK installed directory is C:\Program Files\Java\jdk1.7.0_25, then the path which should be used used in ColdFusion would be C:\\Program Files\\Java\\jdk1.7.0_25\\jre or C:/Program Files/Java/jdk1.7.0_25/jre.
 
 
 
 
Please leave your comments and queries about this post in the comment sections in order for me to improvise my skills.
Advertisements

Author: Nimit Sharma

Hey I am Nimit Sharma, Working as a Lead Software Engineer. I am willing to learn new concepts and technologies. All content here are my personal views and not those of my employer.

4 thoughts on “How to change/upgrade JDK version of ColdFusion server”

    1. ColdFusion uses jvm.config to read jvm related information even on non-windows platforms. On contrary, If ColdFusion is deployed on JEE servers then jvm.config will not come in the picture. In that case, we need to make required changes in the configuration file of the respective application server. Though, it is a good point. I will incorporate this information in the blog. Thanks for your feedback.

      1. Yes, it does support the standard way of setting this.

        JRE is baked in the ColdFusion server for all the platform. So by default, ColdFusion does not try to locate JRE installed on the machine. However, if you want to upgrade or change the JRE of ColdFusion to the specific JRE version, then you may want to update “java.home” property in jvm.config file to point it to the location of the JRE which you may intend to use, because ColdFusion will always prefer “java.home” setting defined in the jvm.config. If you want to fallback on the standard way of setting this, then you should comment “java.home” property from the jvm.config.

        ColdFusion uses the same approach across all the platform.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s