Professional Documents
Culture Documents
Starting JIRA Automatically On Linux - Atlassian Documentation
Starting JIRA Automatically On Linux - Atlassian Documentation
Starting JIRA Automatically On Linux - Atlassian Documentation
Linux/Solaris system administration is outside the scope of Atlassian support. This page is provided for
your information only.
On Linux/Solaris, the best practice is to install, configure and run each service (including JIRA) as a dedicated user
with only the permissions they require.
1. Create a jira user account which will be used to run JIRA. For example, enter the following at a Linux/Solaris
console:
sudo su - jira
4. Assuming you downloaded the JIRA from a 'tar.gz' archive, you need to extract it:
cd /opt/atlassian/jira
tar zxvf /tmp/atlassian-jira-X.Y.tar.gz
ln -s atlassian-jira-X.Y/ current
#!/bin/sh -e
# JIRA startup script
#chkconfig: 2345 80 05
#description: JIRA
case "$1" in
# Start command
start)
echo "Starting $APP"
/bin/su -m $USER -c "cd $BASE/logs && $BASE/bin/startup.sh &> /dev/null"
;;
# Stop command
stop)
echo "Stopping $APP"
/bin/su -m $USER -c "$BASE/bin/shutdown.sh &> /dev/null"
echo "$APP stopped successfully"
;;
# Restart command
restart)
$0 stop
sleep 5
$0 start
;;
*)
echo "Usage: /etc/init.d/$APP {start|restart|stop}"
exit 1
;;
esac
exit 0
8. Place symlinks in the run-level directories to start and stop this script automatically.
The following commands will be executed to place symlinks in the run-level directories:
9. Ensure the script is executed in the correct order, in particular after the database startup script.
Thank you to Matthew Block and Pete Toscano for the original comments that we based this
information on.