coldfusioncommandbox

The Command to start Coldfusion server exits with errors in Command Box


I have been all over trying to figure out what this error means. The project has been just given to me and I have never done anything with cold fusion.

Any help would be appreciated.

What happens is when I try and start the command box I get this error and the server stops.

The command I run to start this server is

server start cfengine=adobe@11 console=true
[INFO ] Runwar: ******************************************************************************
[INFO ] Runwar: Starting RunWAR 4.8.5
[INFO ] Runwar: Binding HTTP on localhost:8282
[INFO ] Runwar: Enabling HTTP/2
[INFO ] Runwar: Servlet Context: /
[INFO ] Runwar: Log Directory: C:\Users\Aaron\.CommandBox\server\DE7764989AC6E02101EEFD566DEBC404-cherokee-leaseapps\adobe-11.0.19.314546\logs
[INFO ] Runwar: ******************************************************************************
[INFO ] Runwar: Parsing 'C:\Users\Aaron\.CommandBox\server\DE7764989AC6E02101EEFD566DEBC404-cherokee-leaseapps\adobe-11.0.19.314546\WEB-INF\web.xml'
[INFO ] Runwar: Creating deployment [default] in C:\Users\Aaron\Documents\dev\cherokee-leaseapps
[INFO ] 05/31 16:08:18 INFO License Service: Flex 1.5 CF Edition enabled
[INFO ] 05/31 16:08:18 INFO Starting Flex 1.5 CF Edition
[INFO ] 05/31 16:08:18 INFO Macromedia Flex Build: 87315.134646
[ERROR] java.lang.NullPointerException
[ERROR]         at coldfusion.CfmServlet.init(CfmServlet.java:97)
[ERROR]         at coldfusion.bootstrap.ClassloaderHelper.initServletClass(ClassloaderHelper.java:121)
[ERROR]         at coldfusion.bootstrap.BootstrapServlet.init(BootstrapServlet.java:59)
[ERROR]         at io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:117)
[ERROR]         at io.undertow.servlet.core.ManagedServlet$DefaultInstanceStrategy.start(ManagedServlet.java:309)
[ERROR]         at io.undertow.servlet.core.ManagedServlet.createServlet(ManagedServlet.java:145)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:588)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:559)
[ERROR]         at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
[ERROR]         at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
[ERROR]         at io.undertow.servlet.api.LegacyThreadSetupActionWrapper$1.call(LegacyThreadSetupActionWrapper.java:44)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl.start(DeploymentManagerImpl.java:601)
[ERROR]         at runwar.Server.createServletDeployment(Server.java:1360)
[ERROR]         at runwar.Server.startServer(Server.java:517)
[ERROR]         at runwar.Start.main(Start.java:51)
[ERROR] javax.servlet.ServletException: java.lang.NullPointerException
[ERROR]         at coldfusion.bootstrap.ClassloaderHelper.initServletClass(ClassloaderHelper.java:129)
[ERROR]         at coldfusion.bootstrap.BootstrapServlet.init(BootstrapServlet.java:59)
[ERROR]         at io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:117)
[ERROR]         at io.undertow.servlet.core.ManagedServlet$DefaultInstanceStrategy.start(ManagedServlet.java:309)
[ERROR]         at io.undertow.servlet.core.ManagedServlet.createServlet(ManagedServlet.java:145)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:588)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:559)
[ERROR]         at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
[ERROR]         at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
[ERROR]         at io.undertow.servlet.api.LegacyThreadSetupActionWrapper$1.call(LegacyThreadSetupActionWrapper.java:44)
[ERROR]         at io.undertow.servlet.core.DeploymentManagerImpl.start(DeploymentManagerImpl.java:601)
[ERROR]         at runwar.Server.createServletDeployment(Server.java:1360)
[ERROR]         at runwar.Server.startServer(Server.java:517)
[ERROR]         at runwar.Start.main(Start.java:51)
[ERROR] Caused by: java.lang.NullPointerException
[ERROR]         at coldfusion.CfmServlet.init(CfmServlet.java:97)
[ERROR]         at coldfusion.bootstrap.ClassloaderHelper.initServletClass(ClassloaderHelper.java:121)
[ERROR]         ... 13 more
[INFO ] Runwar: ******************************************************************************
[INFO ] Runwar: *** stopping server 'cherokee-leaseapps' (socket 49490)
[INFO ] Runwar: ******************************************************************************

Server's output stream closed. It's been stopped elsewhere.

Stopping server...



ERROR (5.9.0+00721)

Server process returned failing exit code [1]

Solution

  • You're running ColdFusion 11, the latest version of Java that can be used is Java 8, but only with at least hotfix 3.

    https://coldfusion.adobe.com/2021/01/table-of-java-to-cf-versions/

    To clarify, CommandBox runs on the version of Java that came with it. By default, all CFML servers will use the version that CB uses. But you can run each instance of a CFML engine on a version of Java specific to it.

    You'll have to install the latest version of Java 7 to start. Then apply the hotfixes, then install Java 8. You can tell the server instance to use a specific version of Java with the correct config values.

    Create a file server.json in the root of your CF application. This is where you can set the server values instead of at the command line. Now you should be able to run server start.

    {
        "name": "cf11server",
        "console": true,
        "jvm": {
            "javaHome": "c://path//to//java//8//bin",
        },
        "app": {
            "cfengine": "adobe@11",
        }
    }
    

    There are a lot of settings you can configure for each server you create in CommandBox.