Configuring web servers

This section describes how to configure a web server to serve ColdFusion pages, for Windows and UNIX. Do this if you did not configure a web server automatically during installation, or to change your web server.

Note:   If you cannot verify your configuration, repeat the procedure. If the problem persists, contact Macromedia Technical Support for assistance, or manually create the element that you cannot verify in the configuration (for example, manually add an entry to the Apache web server properties file, as documented in this section).

Configuring web servers in Windows

This section explains how to configure the following web servers in Windows:

Configuring Internet Information Server (IIS) in Windows

This section describes how to configure Internet Information Server (IIS) for ColdFusion MX in Windows, and how to verify your configuration.

Note:   The Macromedia ColdFusion MX team has tested integration with the .Net Framework version 1 and Service Pack 1.

To configure IIS for ColdFusion MX in Windows:

  1. Select Start > Run, and enter cmd.
  2. At the command prompt, enter the following command on a single line:
    cf_root\runtime\jre\bin\java -cp cf_root\runtime\lib 
    -jar cf_root\runtime\lib\wsconfig.jar -ws IIS -site "0" 
    -map .cfm,.cfc,.cfml,.jsp -v
    

    Note:   You must enter the previous command as a single (long) line.

    The following is a sample command:

    c:\cfusionmx\runtime\jre\bin\java -cp c:\cfusionmx\runtime\lib 
    -jar c:\cfusionmx\runtime\lib\wsconfig.jar -ws IIS -site "0" 
    -map .cfm,.cfc,.cfml,.jsp -v
    

This adds the appropriate IIS application mappings for ColdFusion MX.

If necessary, ColdFusion MX generates the following log file for errors: cf_root\runtime\lib\wsconfig\wsconfig.log.

To verify your IIS configuration:

  1. Verify that the following file was created: cf_root/runtime/lib/wsconfig/jrun.dll.
  2. For each of your IIS websites, verify that application mappings for .cfm, .cfml, .cfc, and .jsp were added, as follows:
    1. In IIS, right-click an IIS website and select Properties.
    2. In the Properties dialog box, on the Home Directory tab, click Configuration.
    3. In the Application Configuration dialog box, click the App Mappings tab.

      The new application mappings appear, as the following figure shows:

      Application Configuration dialog box with IIS application mappings for ColdFusion MX

  3. Verify that each of your IIS websites has a virtual directory called JRunScripts.

    The following figure shows a sample JRunScripts virtual directory:

    The IIS virtual directory for ColdFusion MX, called JRunScripts

  4. Verify that the JRunScripts directory in each of your IIS websites points to the correct location, as follows:
    1. Right-click the JRunScripts directory and select Properties.
    2. In the Properties dialog box, on the Virtual Directories tab, verify that the Local Path text box contains the following path:

      cf_root/runtime/lib/wsconfig/1/

      The following figure shows a sample Properties dialog box for the JRunScripts virtual directory:

      Properties dialog box for the IIS

Configuring Netscape Enterprise or iPlanet web server in Windows

This section describes how to configure Netscape Enterprise web server 3.6x or iPlanet web server (4.x or 6.x) for ColdFusion MX in Windows, and how to verify your configuration.

To configure Netscape or iPlanet for ColdFusion MX in Windows:

  1. Select Start > Run, and enter cmd.
  2. At the command prompt, enter the following command on a single line:
    cf_root\runtime\jre\bin\java -cp cf_root\runtime\lib 
    -jar cf_root\runtime\lib\wsconfig.jar -ws <Iplanet or NES> 
    -dir <Netscape/iPlanet config directory> -v
    

    Note:   You must enter the previous command as a single (long) line.

    The following is a sample command:

    c:\cfusionmx\runtime\jre\bin\java -cp c:\cfusionmx\runtime\lib 
    -jar c:\cfusionmx\runtime\lib\wsconfig.jar -ws NES 
    -dir c:\netscape\server4\https-yourserver\config -v
    

To verify your Netscape or iPlanet configuration:

  1. Verify that the following file was created:
    cf_root\runtime\lib\wsconfig\1\jrun_nsapi35.dll
  2. Open the Netscape configuration file, obj.conf, in the web server directory (for example, in c:\netscape\server4\https-yourserver\config\obj.conf).
  3. Verify that the following line was added to the file:
    NameTrans fn="jrunfilter"
    
  4. Verify that #JRun prefixes the following NameTrans line in the file:
    #JRun NameTrans fn="pfx2dir" from="/servlet" 
    dir="e:/netscape/servers/docs/servlet" 
    
  5. Verify that the following object element is at the end of the file:
    <Object name="jrun">
    PathCheck fn="jrunfilter"
    Service fn="jrunservice"
    </Object>
    

Configuring Apache web server in Windows

This section describes how to configure the Apache web server for ColdFusion MX in Windows, and how to verify your configuration.

To configure Apache for ColdFusion MX in Windows:

  1. Select Start > Run, and enter cmd.
  2. At the command prompt, enter the following command on a single line:
    cf_root\runtime\jre\bin\java -cp cf_root\runtime\lib 
    -jar cf_root\runtime\lib\wsconfig.jar -ws Apache 
    -dir <Apache conf directory> -v
    

    Note:   You must enter the previous command as a single (long) line.

    The following is a sample command:

    c:\cfusionmx\runtime\jre\bin\java -cp c:\cfusionmx\runtime\lib 
    -jar c:\cfusionmx\runtime\lib\wsconfig.jar -ws Apache 
    -dir c:\Program Files\Apache Group\Apache\conf -v
    

To verify your Apache configuration:

  1. Verify that the following file was created:
    cf_root\runtime\lib\wsconfig\1\mod_jrun.so
  2. Open the Apache configuration file, httpd.conf, in your Apache conf directory. By default it is c:\Program Files\Apache Group\Apache\conf\httpd.conf.

    Verify that the following code is appended to this file:

    # JRun Settings
    LoadModule jrun_module "c:/CFusionMX/runtime/lib/wsconfig/1/mod_jrun.so"
    <IfModule mod_jrun.c>
        JRunConfig Verbose false
        JRunConfig Apialloc false
        JRunConfig Ssl false
        JRunConfig Serverstore "c:/CFusionMX/runtime/lib/wsconfig/1/
    jrunserver.store"
        JRunConfig Bootstrap 127.0.0.1:51000
        #JRunConfig Errorurl <URL for errors>
    </IfModule>
    

Configuring web servers on UNIX

This section explains how to configure the following web servers on UNIX:

Configuring Apache web server on UNIX

This section describes how to configure the Apache web server for ColdFusion MX on UNIX, and how to verify your configuration.

To configure the Apache web server for ColdFusion MX on UNIX:

To verify your Apache configuration:

  1. Verify that the following file was created:
    cf_root/runtime/lib/wsconfig/1/mod_jrun.so
  2. Open the Apache configuration file, httpd.conf, in your Apache conf directory. By default it is /etc/httpd/conf/httpd.conf.

    Verify that the following code is appended to this file:

    # JRun Settings
    LoadModule jrun_module "/opt/coldfusionmx/runtime/lib/wsconfig/1/mod_jrun.so"
    <IfModule mod_jrun.c>
        JRunConfig Verbose false
        JRunConfig Apialloc false
        JRunConfig Ssl false
        JRunConfig Serverstore "/opt/coldfusionmx/runtime/lib/wsconfig/1/
    jrunserver.store"
        JRunConfig Bootstrap 127.0.0.1:51000
        #JRunConfig Errorurl <URL for errors>
    </IfModule>
    

Configuring Netscape or iPlanet web server on UNIX

This section describes how to configure Netscape Enterprise web server 3.6x or iPlanet web server (4.x or 6.x) for ColdFusion MX on UNIX, and how to verify your configuration.

To configure Netscape or iPlanet for ColdFusion MX on UNIX:

To verify your Netscape or iPlanet configuration:

  1. Verify that the following file was created:
    cf_root/runtime/lib/wsconfig/1/jrun_nsapi35.dll
  2. Open the Netscape configuration file, obj.conf, in the web server directory (for example, in /usr/netscape/server4/https-surf/config/obj.conf).
  3. Verify that the following line is in the file:
    NameTrans fn="jrunfilter"
    
  4. Verify that #JRun prefixes the following NameTrans line in the file:
    #JRun NameTrans fn="pfx2dir" from="/servlet" 
    dir="e:/netscape/servers/docs/servlet" 
    
  5. Verify that the following object element is at the end of the file:
    <Object name="jrun">
    PathCheck fn="jrunfilter"
    Service fn="jrunservice"
    </Object>
    

Comments