Tuesday, March 2, 2010

JIRA WAR Tomcat Installation

I have been trying to setup a single Tomcat 6.0.x server to maintain a number of project lifecycle apps. One of these apps is JIRA. I found documentation that described how to setup JIRA as an EAR/WAR. However the method defined involved copying was a number of jar files into the Tomcat server lib directory that I was uncomfortable with. I wanted to keep the number of jars going into the server lib folder to a minimum. After some work, the only jar I had to put in the tomcat/lib folder was the MySQL JDBC driver.

The following instructions describe the steps that I took to achieve this.

  • MacOSX (Snow Leopard)
  • JIRA version 4.0.2
  • MySQL

1. Download the EAR/WAR version of JIRA (NOTE if it isn't visible on the downloads page then look for the small link that says "Show All" rather than just recommended.

2. Once downloaded, unpack the archive to a folder. From now on know as $JIRA_INSTALL. According to the Atlassian website there have been reported problems with the Windows extractor not extracting all files and a similar situation with WinRAR. Try using WinZip or another alternative.

3. Download and install mysql. This is beyond the scope of this post but there are plenty of good howto's and tutorials out there on how to do it.

4. Once my sql is installed we need to create a user for our jira database. Run the following commands to create the user replacing the changeme100 with your desired password:

5. Now we need to create the jira db. Log into MySQL as an administrator and run the following commands replacing the changeme100 with your desired password:

CREATE DATABSE jiradb character set utf8;
CREATE USER 'jira'@'localhost' IDENTIFIED BY 'changeme100';

6. Download the mysql Connector/J JDBC driver and place the jar file in your $CATALINA_HOME/lib folder.

7. Open $JIRA_INSTALL/edit-webapp/WEB-INF/class/entityengine.xml in a text editor and change the

<datasource name="defaultDS" class="org.ofbiz.core.entity.GenericHelperDAO" keys="false" indices="false" start="true">
<jndi-jdbc name="default">


<datasource name="defaultDS" class="org.ofbiz.core.entity.GenericHelperDAO" keys="false" indices="false" check="" start="true">
<jndi-jdbc name="default">

8. Open $JIRA_INSTALL/edit-webapp/WEB-INF/classes/jira-application.properties in a text editor and change the "jira.home" property near the top of the file to an absolute folder. I'm using /usr/share/jira.

10. Download the required Tomcat jars for JIRA to work. Unzip the folder and copy the contents (jar files) into the $JIRA_INSTALL/webapp/WEB-INF/lib folder.

11. Create a new folder called META-INF in the $JIRA_INSTALL/edit-webapp/META-INF folder and then create a new file called context.xml inside it. Open this file up in a text editor and add the following contents:

<context path="/jira">
<resource name="jdbc/JiraDS" auth="Container" type="javax.sql.DataSource" username="jira" password="changeme100" driverclassname="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost/jiradb"/>

<resource name="UserTransaction" auth="Container" type="javax.transaction.UserTransaction" factory="org.objectweb.jotm.UserTransactionFactory" timeout="60">
<manager pathname=""/>

12. Now in a command window go to the $JIRA_INSTALL folder and run build.bat (Windows) or ./build.sh (Unix/Linux/Mac).

13. Once the build is complete copy the $JIRA_INSTALL/dist-tomcat/atlassian-jira-4.0.2.war to your $CATALINA_HOME/webapps folder

14. You should now be able to start up your tomcat instance and browse to http://localhost:8080/jira.

Please let me know if you have any issues or problems :)


  1. Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a Java developer learn from Java Training in Chennai. or learn thru Java Online Training from India . Nowadays Java has tons of job opportunities on various vertical industry.

  2. Really very nice blog information for this one and more technical skills are improve,i like that kind of post.
    Best Devops online Training
    Online DevOps Certification Course - Gangboard

  3. It seems you are so busy in last month. The detail you shared about your work and it is really impressive that's why i am waiting for your post because i get the new ideas over here and you really write so well.

    Selenium training in Chennai
    Selenium training in Bangalore
    Selenium training in Pune
    Selenium Online training
    Selenium training in bangalore

  4. Thank you for benefiting from time to focus on this kind of, I feel firmly about it and also really like comprehending far more with this particular subject matter. In case doable, when you get know-how, is it possible to thoughts modernizing your site together with far more details? It’s extremely useful to me
    online Python training
    python training in chennai

  5. Saved as a favorite, I really like your site! See this website: How To Password Protect Folder In 10 Minutes And Still Look Your Best

  6. Good Post! Thank you so much for sharing this pretty post, it was so good to read and useful to improve my knowledge as updated one, keep blogging.
    Selenium Training in Electronic City

  7. Whatever we gathered information from the blogs, we should implement that in practically then only we can understand that exact thing clearly, but it’s no need to do it, because you have explained the concepts very well. It was crystal clear, keep sharing..
    Java Training in Chennai
    Java Training in Coimbatore
    Java Training in Bangalore

  8. thanks for your information really good and very nice web design company in velachery

  9. Nice blog! Full of informative ideas. Thank you, keep sharing.
    web design company in chennai

  10. Great blog thanks for sharing Your website is the portal to your brand identity. The look and feel of every page carry a strong message. This is why your brand needs the best web design company in chennai to capture your visions and make it art. Adhuntt Media is graced with the most creative design team in Chennai.
    digital marketing company in chennai
    seo service in chennai
    web designing company in chennai
    social media marketing company in chennai

  11. Nice blog thanks for sharing Evolve past boring simple rooftops and bling them up by converting your upstairs to a terrace garden. Interested? Get your very own at Karuna Nursery Gardens - the best terrace garden service in Chennai.
    plant nursery in chennai
    rental plants in chennai
    corporate gardening service in chennai

  12. Excellent blog thanks for sharing Run your salon business successfully by tying up with the best beauty shop in Chennai - The Pixies Beauty Shop. With tons of prestigious brands to choose from, and amazing offers we’ll have you amazed.
    Cosmetics Shop in Chennai

  13. Very useful blog thanks for sharing IndPac India the German technology Packaging and sealing machines in India is the leading manufacturer and exporter of Packing Machines in India.

  14. This excellent website certainly has all the info I needed concerning this subject and didn’t know who to ask.
    Tech geek

  15. After a lead generation, the entire revenue goes to the course instructor. For instance, if a lead is generated through the coupon code given by the course creator, the instructor will get the revenue. cursos de ti online

  16. Concept involves in the contents are very beneficial, put the hands together for all your Effective works.To get More Beneficial Click on here...