Documentation for JIRA 4.2. Documentation for other versions of JIRA is available too.

Skip to end of metadata
Go to start of metadata
Unable to render {include} The included page could not be found.
Install

These instructions will help you install JIRA on IBM Websphere 6.x.

On this page:

1. Unpack JIRA

Download and unzip JIRA (but not with XP's unzipper nor the default tar utility on Solaris). Ensure that you download the WAR/EAR version, not the Standalone version that is recommended on the Downloads page.
Avoid the Windows XP built-in unzip tool! The built-in unzip tool in Windows XP is broken — it silently fails to extract files with long names (see JRA-2153 ). Other users have also reported problems using WinRAR. Please use another tool like WinZIP to unpack JIRA.
Avoid the Solaris default tar utility! On Solaris, please use GNU tar to unpack JIRA in order to handle long filenames. Do not use the Solaris default tar utility.

A new directory containing JIRA will be created, hereafter referred to as $JIRA_INSTALL.

A dedicated user should be created to run JIRA, as JIRA runs as the user it is invoked under and therefore can potentially be abused. Here is an example of how to create a dedicated user to run JIRA in Linux/Solaris:

$ sudo /usr/sbin/useradd --create-home --home-dir /usr/local/jira --shell /bin/bash jira

To maximise security, ensure that this user can only write to the JIRA directories (not to the entire file system).


2. Configure JIRA

2.1 Configure entityengine.xml

The edit-webapp/WEB-INF/classes/entityengine.xml file needs to be modified to specify the correct database field type. The example below is configured for MS SQL Server.

  • In the Transaction Factory section:
    Please remove "/env" if it is there, i.e. change this:
    <transaction-factory class="org.ofbiz.core.entity.transaction.JNDIFactory">
          <user-transaction-jndi jndi-server-name="default" jndi-name="java:comp/env/UserTransaction"/>
          <transaction-manager-jndi jndi-server-name="default" jndi-name="java:comp/env/UserTransaction"/>
        </transaction-factory>
    to this:
    <transaction-factory class="org.ofbiz.core.entity.transaction.JNDIFactory">
          <user-transaction-jndi jndi-server-name="default" jndi-name="java:comp/UserTransaction"/>
          <transaction-manager-jndi jndi-server-name="default" jndi-name="java:comp/UserTransaction"/>
        </transaction-factory>
  • In the Datasource section:
    Please ensure that the value of the jndi-jdbc/jndi-name attribute has the "java:comp/env" prefix. The prefix should be in the file by default.
    <datasource name="defaultDS" field-type-name="mssql"
        helper-class="org.ofbiz.core.entity.GenericHelperDAO"
        check-on-start="true" use-foreign-keys="false"
        use-foreign-key-indices="false"
        check-fks-on-start="false"
        check-fk-indices-on-start="false"
        add-missing-on-start="true">
        <jndi-jdbc jndi-server-name="default" jndi-name="java:comp/env/jdbc/JiraDS"/>
    </datasource>
    		

Warning

Make sure that your entityengine.xml is well-formed XML. Websphere "swallows" the error messages you should get in your log file if entityengine.xml is not well-formed, and instead reports a spurious error message.
You can test that your entityengine.xml is well-formed by opening it in Internet Explorer or Firefox. These browsers will display an error if the file is not well-formed XML, and will indicate the location of the error in the file.

2.2 Set JIRA Home

To specify the location of your JIRA Home Directory (note that you need to do this before you build JIRA):
  • Edit the jira-application.properties file (see the JIRA Installation Directory page to find where this file is located), add a 'jira.home' property and set it to your desired location for the JIRA home directory. Please use forward-slashes ("/"), not back-slashes ("\").
You can specify any location on a disk for your JIRA home directory. Please be sure to specify an absolute path.

Please note that you cannot use the same JIRA home directory for multiple instances of JIRA. We recommend that you do not specify your JIRA home directory to be inside your installation directory, to prevent information from being accidentally lost during major operations (e.g. backing up and restoring instances).

2.3 Modify web.xml

Edit webapp/WEB-INF/web.xml file and remove lines:

<!-- Uncomment for WebSphere
Uncomment for WebSphere -->
                

which appear towards the bottom of the file. After removing the lines the <resource-ref> entry should look like:

<!-- resource references -->
<resource-ref>
    <description>Database for JIRA</description>
    <res-ref-name>jdbc/JiraDS</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>SERVLET</res-auth>
    <res-sharing-scope>Unshareable</res-sharing-scope>
</resource-ref>
                

Please ensure that the res-sharing-scope is set to Unshareable.

3. Build JIRA

Now build JIRA by running the build script for your platform (e.g. build.bat on Windows or build.sh on a Unix or Linux system). This will produce the deployable WAR file in the dist-generic directory.

4. Configure the Websphere datasource

4.1 Download the datasource

4.2 Configure the datasource

Perform the following steps in the Websphere Administration Console.

4.2.1 Create a JDBC Provider

Click Resources -> JDBC Providers, and create a new JDBC Provider for the database you wish to deploy to.

  • Set the Classpath field to include the JDBC driver jar.
  • In the Implementation Classname field, you need to enter the name of a DataSource implementation classname, not the JDBC driver classname. For instance, the MySQL JDBC driver class is 'com.mysql.jdbc.Driver', but here we need to enter 'com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource'.

Consult your database documentation for details.

4.2.2 Create a DataSource

Now select your newly created JDBC Provider, and add a DataSource (the name of the DataSource doesn't matter).

The important thing to get right here is the JNDI Name. This must be the same as that specified in your webapp. For JIRA, that means it has to correspond to:

<jndi-jdbc jndi-server-name="default" jndi-name="jdbc/JiraDS"/>

in WEB-INF/classes/entityengine.xml.

4.2.3 Configure the DataSource

In the 'Custom Properties' section, specify the username and password which JIRA will use to connect to the database, and the JDBC URL to use.

4.2.4 Test the connection

Test the connection, and if it all works, save the changes.

5. Deploy JIRA in Websphere

The JIRA WAR file can now be deployed to Websphere (by e.g. using Websphere's Administration Console). Note that you must:

  1. Bind JIRA's jdbc/JiraDS datasource to Websphere's jdbc/JiraDS entry.
  2. Enable application-first (parent-last) classloading, the 'Classes loaded with application class loader first' and the 'Single classloader for application' WAR classloader policy.
  3. Use the WAR file in dist-generic directory and NOT the dist-tomcat directory.
  4. Turn WebSphere's "Servlet Caching" off. Otherwise JIRA will die with ClassCastExceptions.

6. Set mail.mime.decodeparameters

The following system property must be set in order for the JIRA mail handler to work correctly with emails from RFC 2231-compliant mail clients:
mail.mime.decodeparameters=true

Refer to Setting Properties and Options on Startup for instructions.

7. Ensure Websphere compiles JSPs in Java 1.5

To ensure that Websphere compiles JSPs in Java 1.5 successfully, you must:

  1. Edit the ibm-web-ext.xmi bindings file located within the WEB-INF directory of your Websphere Application Server's WAR file.
    The following example shows a typical location for this binding file:
    <WAS-HOME>/profiles/AppSrv01/config/cells/<cellname>/applications/<jira-appname>/deployments/<jira-appname.war>/WEB-INF/ibm-web-ext.xmi
    
  2. Add the following entry into this bindings file:
    <jspAttributes xmi:id="JSPAttribute_[number]" name="jdkSourceLevel" value="15"/>
    (warning) [number] must be a unique integer with respect to the other <jspAttributes xmi:id="JSPAttribute_[number]"... entries in this file.

  3. Save the updated ibm-web-ext.xmi bindings file.

For more information, please refer to the following references:

8. Start JIRA

When you access the path at which you have deployed JIRA, via your web browser, the Setup Wizard should appear.

User-contributed notes

Have experiences to share with Websphere 6.x and JIRA? We welcome your thoughts. Please see the user-contributed Websphere notes.