1、java环境配置
yum install java
yum install java- -devel
安装验证 java javac
2、mysql配置
(1)CentOS 7的yum源中貌似没有正常安装mysql时的mysql-sever文件,需要去官网上下载
wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm
rpm -ivh mysql-community-release-el7-5.noarch.rpm
yum install mysql-community-server
(2)成功安装之后重启mysql服务
service mysqld restart
(3)初次安装mysql是root账户是没有密码的,设置密码
mysql -u root
mysql> set password for ‘root’@‘localhost’ = password('mypasswd');
mysql> set password for ‘root’@‘%’ = password('mypasswd');
mysql> grant all privileges on *.* to 'root'@'%' identified by 'mypasswd' with grant option;
mysql> grant all privileges on *.* to 'root'@'localhost' identified by 'mypasswd' with grant option;
mysql> FLUSH PRIVILEGES;
mysql> create database jiradb character set 'UTF8';
3、JIRE下载和安装
(1)下载地址(内含破解和汉化补丁)
下载地址1:http://pan.baidu.com/s/1o7nuzME
下载地址2:http://pan.baidu.com/s/1c1lrLs密码:nse1
下载后提取主文件atlassian-jira-6.3.6.tar.gz
(2)安装
cd /home
mkidr JIRA
cd JIRA
tar -xzvf atlassian-jira-6.3.6.tar.gz ./
mkidr JIRA_HOME
修改JIRA配置,指定jira_home,即:
vim /home/JIRA/jira-6.3.6-*/atlassian-jira/WEB-INF/classes/jira-application.properties
jira.home = /home/JIRA/JIRA_HOME
安装JIRA需要用到的MySQL驱动包
cp mysql-connector-java-5.1.7-bin.jar /home/JIRA/jira-6.3.6-*/atlassian-jira/WEB-INF/WEB-INF/lib
启动安装(8080端口)
安装key:
AAABBw0ODAoPeNptkFtLxDAQhd/zKwI+R9Kwy66FPKxthGhvtF0p4kuso0a6sUwvuP/edissyj4MDHPOfHOYqzu0tICWeoJy4a+FzzkNwpIK7q1ICF2Ntu3tl5P3Ot89+1SNphnMPCEBwqkJTQ9y9jN+wzxBPi2a68jW4DpQr/a0rZJS5VmuC0XOBNnjAH/s5bGFxBxABmkcqzzQu2jRTd3bEZaFZvE+AnYzRJDYWNeDM64G9d1aPJ4TeXxOlOK7cbZbjrbNgkyGwwtg+rbvJpBkHikAR0Adytt0XzFV7R5Y+qQzVkWZIoVK5FQsWq03YrvdkN/Ekz3S4SXlcpRswPrDdPD/aT+P1nzDMC0CFQCM9+0LlHVNnZQnSTwuRO3eK+2gVgIUCteTs4Q3khIgrnsY64hxYB/d8bM=X02dh
(3)破解
cp atlassian-extras-2.2.2.jar /home/JIRA/jira-6.3.6-*/atlassian-jira/WEB-INF/lib
cp atlassian-universal-plugin-manager-plugin-2.17.13.jar /home/JIRA/jira-6.3.6-*/atlassian-jira/WEB-INF/atlassian-bundled-plubins/
在web授权页面更新授权
Description=JIRA: Commercial,
CreationDate=2015-08-17,
jira.LicenseEdition=ENTERPRISE,
Evaluation=false,
jira.LicenseTypeName=COMMERCIAL,
jira.active=true,
licenseVersion=2,
MaintenanceExpiryDate=2099-12-31,
Organisation=pl,
SEN=SEN-L4572887,
ServerID=B7OT-4FTO-HTCL-TU0W,
jira.NumberOfUsers=-1,
LicenseID=AAABBw0ODAoPeNptkFtLxDAQhd/zKwI+R9Kwy66FPKxthGhvtF0p4kuso0a6sUwvuP/edissyj4MDHPOfHOYqzu0tICWeoJy4a+FzzkNwpIK7q1ICF2Ntu3tl5P3Ot89+1SNphnMPCEBwqkJTQ9y9jN+wzxBPi2a68jW4DpQr/a0rZJS5VmuC0XOBNnjAH/s5bGFxBxABmkcqzzQu2jRTd3bEZaFZvE+AnYzRJDYWNeDM64G9d1aPJ4TeXxOlOK7cbZbjrbNgkyGwwtg+rbvJpBkHikAR0Adytt0XzFV7R5Y+qQzVkWZIoVK5FQsWq03YrvdkN/Ekz3S4SXlcpRswPrDdPD/aT+P1nzDMC0CFQCM9+0LlHVNnZQnSTwuRO3eK+2gVgIUCteTs4Q3khIgrnsY64hxYB/d8bM=X02dh,
LicenseExpiryDate=2099-12-31,
PurchaseDate=2015-08-17
(4)汉化
插件管理上传插件JIRA-6.3.3-language-pack-zh_CN.jar并在系统设置中更改语言为中文(chinese)
(5)运行测试
cd /home/JIRA/jira-6.3.6-*/bin
./start-jira.sh
4、开机启动脚本jirad
将下面的内容保存为shell脚本文件jirad,并将其放如目录/etc/init.d/下
chkconfig --add jirad将脚本添加到开机启动配置中;
chkconfig -s jirad 设置开机启动;
注:Jira变量为JIRE安装包解压之后的目录所在的路径
#!/bin/bash
#chkconfig: 2345 85 15
#description: jira
#processname: jira
#./etc/init.d/functions
Jira=/root/JIRA/atlassian-jira-6.3.6-standalone
startup=$Jira/bin/start-jira.sh
shutdown=$Jira/bin/stop-jira.sh
#export JAVA_HOME=/usr/local/java/jdk1.6.0_22
#export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.111-2.b15.el7_3.x86_64
rm -rf /root/JIRA/JIRA_HOME/.jira-home.lock
start(){
echo -n $"Starting Jira"
#daemon -c
$startup
RETVAL=$?
echo
}
stop(){
echo $"Stopping Jira"
$shutdown
RETVAL=$?
echo
}
restart(){
stop
sleep 10
start
}
status(){
numproc=`ps -ef | grep jira | grep -v "grep jira" | wc -l`
if [ $numproc -gt 0 ]; then
echo "Jira is running..."
else
echo "Jira is stopped..."
fi
}
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
status)
status
;;
restart)
restart
;;
*)
echo $"Usage: $0 {start|stop|status|restart}"
exit 1
esac
exit 0
[参考文献]http://blog.163.com/sujoe_2006/blog/static/3353151201622352112244/