1,安裝前準(zhǔn)備
1.1,環(huán)境準(zhǔn)備
你要先安裝好Java和Mysql
1.2,Jira軟件準(zhǔn)備
你可以下載任意的8.x軟件,我這里直接從Atlassian下載的是8.7.x版本
atlassian-jira-software-8.5.4-x64.bin
1.3,Jira破解包準(zhǔn)備
打開(kāi) https://gitee.com/pengzhile/atlassian-agent/releases 下載 atlassian-agent.jar
將其下載到服務(wù)器某個(gè)目錄下
1.4,Mysql鏈接包準(zhǔn)備
從mysql的官網(wǎng)下載對(duì)應(yīng)的鏈接包
mysql-connector-java-5.1.48.tar.gz
現(xiàn)在你應(yīng)該準(zhǔn)備好了以下內(nèi)容
[root@...wh2h6as05hZ... package]# ll
total 1308844
-rw-r--r-- 1 root root 1016719 May 10 18:50 atlassian-agent-v1.2.3.tar.gz
-rwxrwxrwx 1 root root 388912276 May 10 18:43 atlassian-jira-software-8.5.4-x64.bin
-rw-r--r-- 1 root root 4456335 May 10 18:41 mysql-connector-java-5.1.48.tar.gz
2,開(kāi)始安裝
2.1,賦予執(zhí)行權(quán)限
進(jìn)入你下載好atlassian軟件包的目錄,同時(shí)你需要有執(zhí)行的權(quán)限,如果沒(méi)有可以使用一下命令
[root@...wh2h6as05hZ... package]#
chmod 777
atlassian-jira-software-8.5.4-x64.bin
2.2,創(chuàng)建安裝目錄
[root@...wh2h6as05hZ... local]# mkdir jira
[root@...wh2h6as05hZ... jiar]#
mkdir
soft
data
crack
2.3,開(kāi)始安裝
[root@...wh2h6as05hZ... package]# ./atlassian-jira-software-8.5.4-x64.bin
Unpacking JRE ...
Starting Installer ...
This will install JIRA Software 8.5.4 on your computer.
OK [o, Enter], Cancel [c]
o
Click Next to continue, or Cancel to exit Setup.
Choose the appropriate installation or upgrade option.
Please choose one of the following:
Express Install (use default settings) [1], Custom Install (recommended for advanced users) [2, Enter], Upgrade an existing JIRA installation [3]
2
Select the folder where you would like JIRA Software to be installed.
Where should JIRA Software be installed?
[/opt/atlassian/jira]
/usr/local/jira/soft
Default location for JIRA Software data
[/var/atlassian/application-data/jira]
/usr/local/jira/data
Configure which ports JIRA Software will use.
JIRA requires two TCP ports that are not being used by any other
applications on this machine. The HTTP port is where you will access JIRA
through your browser. The Control port is used to startup and shutdown JIRA.
Use default ports (HTTP: 8080, Control: 8005) - Recommended [1, Enter], Set custom value for HTTP and Control ports [2]
2
HTTP Port Number
[8080]
8800
Control Port Number
[8005]
8805
JIRA can be run in the background.
You may choose to run JIRA as a service, which means it will start
automatically whenever the computer restarts.
Install JIRA as Service?
Yes [y, Enter], No [n]
y
Details on where JIRA Software will be installed and the settings that will be used.
Installation Directory: /usr/local/jira/soft
Home Directory: /usr/local/jira/data
HTTP Port: 8800
RMI Port: 8805
Install as service: Yes
Install [i, Enter], Exit [e]
i
Extracting files ...
Please wait a few moments while JIRA Software is configured.
Installation of JIRA Software 8.5.4 is complete
Start JIRA Software 8.5.4 now?
Yes [y, Enter], No [n]
y
Please wait a few moments while JIRA Software starts up.
Launching JIRA Software ...
Installation of JIRA Software 8.5.4 is complete
Your installation of JIRA Software 8.5.4 is now ready and can be accessed
via your browser.
JIRA Software 8.5.4 can be accessed at http://localhost:8800
Finishing installation ...
能看到最后 Finishing 的話說(shuō)明成功了,后面先關(guān)閉Jira的服務(wù)然后再操作其他。
2.4,關(guān)閉服務(wù)
[root@...wh2h6as05hZ... package]#
sudo /usr/local/jira/soft/bin/shutdown.sh
`sMMMMMMMMMMMMMM+
MMMMMMMMMMMMMM
:sdMMMMMMMMMMM
MMMMMM
`sMMMMMMMMMMMMMM+ MMMMMM
MMMMMMMMMMMMMM +MMMMM
:sMMMMMMMMMMM MMMMM
MMMMMM `UOJ
`sMMMMMMMMMMMMM+ MMMMMM
MMMMMMMMMMMMMM +MMMMM
:sdMMMMMMMMMM MMMMM
MMMMMM `UOJ
MMMMMM
+MMMMM
MMMMM
`UOJ
Atlassian Jira
Version : 8.5.4
If you encounter issues starting or stopping JIRA, please see the Troubleshooting guide at https://docs.atlassian.com/jira/jadm-docs-085/Troubleshooting+installation
Server startup logs are located in /usr/local/jira/soft/logs/catalina.out
Using CATALINA_BASE: /usr/local/jira/soft
Using CATALINA_HOME: /usr/local/jira/soft
Using CATALINA_TMPDIR: /usr/local/jira/soft/temp
Using JRE_HOME: /usr/local/jira/soft/jre/
Using CLASSPATH: /usr/local/jira/soft/bin/bootstrap.jar:/usr/local/jira/soft/bin/tomcat-juli.jar
Using CATALINA_PID: /usr/local/jira/soft/work/catalina.pid
PID file found but either no matching process was found or the current user does not have permission to stop the process. Stop aborted.
2.4.1,進(jìn)程文件如果無(wú)法刪除或者修改什么的可以先刪除
[root@...wh2h6as05hZ... package]#
rm /usr/local/jira/soft/work/catalina.pid
rm: remove regular file '/usr/local/jira/soft/work/catalina.pid'?
y
2.5,安裝Mysql鏈接包
先解壓
[root@...wh2h6as05hZ... package]#
tar -zvxf mysql-connector-java-5.1.48.tar.gz
copy帶bin的文件到atlassian安裝目錄
[root@...wh2h6as05hZ... mysql-connector-java-5.1.48]# ll
total 2452
-rw-r--r-- 1 root root 91845 Jul 11 2019 build.xml
-rw-r--r-- 1 root root 250554 Jul 11 2019 CHANGES
-rw-r--r-- 1 root root 18122 Jul 11 2019 COPYING
-rw-r--r-- 1 root root 1006959 Jul 11 2019 mysql-connector-java-5.1.48-bin.jar
-rw-r--r-- 1 root root 1006956 Jul 11 2019 mysql-connector-java-5.1.48.jar
-rw-r--r-- 1 root root 61407 Jul 11 2019 README
-rw-r--r-- 1 root root 63658 Jul 11 2019 README.txt
drwxr-xr-x 8 root root 79 Jul 11 2019 src
[root@...wh2h6as05hZ... mysql-connector-java-5.1.48]#
cp
mysql-connector-java-5.1.48-bin.jar
/usr/local/jira/soft/atlassian-jira/WEB-INF/lib/
2.6,copy破解包到固定的地方
之前我們創(chuàng)建了crack的目錄,就是用來(lái)放破解包的
先解壓
[root@...wh2h6as05hZ... package]#
tar -zvxf atlassian-agent-v1.2.3.tar.gz
._atlassian-agent-v1.2.3
atlassian-agent-v1.2.3/
atlassian-agent-v1.2.3/._LICENSE
atlassian-agent-v1.2.3/LICENSE
atlassian-agent-v1.2.3/atlassian-agent.jar
atlassian-agent-v1.2.3/._shasum.txt
atlassian-agent-v1.2.3/shasum.txt
atlassian-agent-v1.2.3/._README.pdf
atlassian-agent-v1.2.3/README.pdf
copy到crack目錄
[root@...wh2h6as05hZ... package]#
cd atlassian-agent-v1.2.3/
[root@...wh2h6as05hZ... atlassian-agent-v1.2.3]#
cp
atlassian-agent.jar
/usr/local/jira/crack/
2.7,修改jira的配置文件
[root@...wh2h6as05hZ... atlassian-agent-v1.2.3]#
vim /usr/local/jira/soft/bin/setenv.sh
在下面添加命令
export JAVA_OPTS="-javaagent:/usr/local/jira/crack/atlassian-agent.jar ${JAVA_OPTS}"
JAVA_OPTS="-Xms${JVM_MINIMUM_MEMORY} -Xmx${JVM_MAXIMUM_MEMORY} ${JVM_CODE_CACHE_ARGS} ${JAVA_OPTS} ${JVM_REQUIRED_ARGS} ${DISABLE_NOTIFICATIONS} ${JVM_SUPPORT_RECOMMENDED_ARGS} ${JVM_EXTRA_ARGS} ${JIRA_HOME_MINUSD} ${START_JIRA_JAVA_OPTS}"
export JAVA_OPTS
>> export JAVA_OPTS="-javaagent:/usr/local/jira/crack/atlassian-agent.jar ${JAVA_OPTS}" <<
# DO NOT remove the following line
JAVA_HOME="/usr/local/jira/soft/jre/"; export JAVA_HOME
2.8, 啟動(dòng)服務(wù)
[root@iZbp18huwto3wh2h6as05hZ ~]# cd /usr/local/jira/soft/bin/
[root@iZbp18huwto3wh2h6as05hZ bin]# sudo ./start-jira.sh
To run JIRA in the foreground, start the server with start-jira.sh -fg
executing using dedicated user: jira
`sMMMMMMMMMMMMMM+
MMMMMMMMMMMMMM
:sdMMMMMMMMMMM
MMMMMM
`sMMMMMMMMMMMMMM+ MMMMMM
MMMMMMMMMMMMMM +MMMMM
:sMMMMMMMMMMM MMMMM
MMMMMM `UOJ
`sMMMMMMMMMMMMM+ MMMMMM
MMMMMMMMMMMMMM +MMMMM
:sdMMMMMMMMMM MMMMM
MMMMMM `UOJ
MMMMMM
+MMMMM
MMMMM
`UOJ
Atlassian Jira
Version : 8.5.4
If you encounter issues starting or stopping JIRA, please see the Troubleshooting guide at https://docs.atlassian.com/jira/jadm-docs-085/Troubleshooting+installation
Server startup logs are located in /usr/local/jira/soft/logs/catalina.out
Using CATALINA_BASE: /usr/local/jira/soft
Using CATALINA_HOME: /usr/local/jira/soft
Using CATALINA_TMPDIR: /usr/local/jira/soft/temp
Using JRE_HOME: /usr/local/jira/soft/jre/
Using CLASSPATH: /usr/local/jira/soft/bin/bootstrap.jar:/usr/local/jira/soft/bin/tomcat-juli.jar
Using CATALINA_PID: /usr/local/jira/soft/work/catalina.pid
Tomcat started.
出現(xiàn)下圖啟動(dòng)成功

3,數(shù)據(jù)庫(kù)配置
3.1,數(shù)據(jù)庫(kù)端修改
驗(yàn)證數(shù)據(jù)庫(kù)的ssl鏈接
數(shù)據(jù)庫(kù)處于安全考慮,會(huì)自動(dòng)啟用SSL的鏈接方式,查看:
> SHOW VARIABLES LIKE '%ssl%';

由于我們自己測(cè)試,沒(méi)有在服務(wù)器上啟用SSL的鏈接,因此需要關(guān)閉這個(gè)SSL的鏈接限制
找到my.cnf,添加以下內(nèi)容
[root@...wh2h6as05hZ... bin]# find / -name my.cnf
/etc/my.cnf
[root@...wh2h6as05hZ... bin]# vim /etc/my.cnf
[mysqld]
#繞過(guò)ssl登錄
skip_ssl
重啟數(shù)據(jù)庫(kù)服務(wù)
[root@iZbp18huwto3wh2h6as05hZ bin]# systemctl restart mysqld
再次驗(yàn)證
> SHOW VARIABLES LIKE '%ssl%';

3.2,Jira的鏈接中取消使用ssl鏈接
3.3,數(shù)據(jù)庫(kù)中創(chuàng)建Jira相關(guān)的數(shù)據(jù)庫(kù)等
atlassian公司貼心的提供了Jira鏈接數(shù)據(jù)庫(kù)的指導(dǎo)網(wǎng)頁(yè)
鏈接到mysql 5.7
https://confluence.atlassian.com/adminjiraserver085/connecting-jira-applications-to-mysql-5-7-981154582.html
3.3.1,創(chuàng)建數(shù)據(jù)庫(kù)
> CREATE DATABASE jiradb CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
--------------------------------------------------
1 queries executed, 1 success, 0 errors, 0 warnings
查詢:CREATE DATABASE jiradb CHARACTER SET utf8mb4 COLLATE utf8mb4_bin
共 1 行受到影響
執(zhí)行耗時(shí) : 0.006 sec
傳送時(shí)間 : 1.001 sec
總耗時(shí) : 1.008 sec

3.3.2,創(chuàng)建對(duì)應(yīng)的用戶
> GRANT ALL ON *.* TO 'jira'@'localhost' IDENTIFIED BY '<PASSWORD>';
> FLUSH PRIVILEGES;
--------------------------------------------------
2 queries executed, 2 success, 0 errors, 1 warnings
查詢:GRANT all on *.* TO 'jira'@'localhost' IDENTIFIED BY '<PASSWORD>'
共 0 行受到影響, 1 個(gè)警告
執(zhí)行耗時(shí) : 0.004 sec
傳送時(shí)間 : 0 sec
總耗時(shí) : 0.005 sec
注意:要查看所有警告的完整列表,請(qǐng)啟用 工具 -> 首選項(xiàng) -> 常規(guī) -> 在信息選項(xiàng)卡下顯示警告
--------------------------------------------------
查詢:flush privileges
共 0 行受到影響
執(zhí)行耗時(shí) : 0.004 sec
傳送時(shí)間 : 0 sec
總耗時(shí) : 0.004 sec
3.3.3,修改mysql的my.cnf配置,添加或者修改如下配置
# 根據(jù)jira的要求進(jìn)行配置
default-storage-engine=INNODB
character_set_server=utf8mb4
innodb_default_row_format=DYNAMIC
innodb_large_prefix=ON
innodb_file_format=Barracuda
innodb_log_file_size=2G
# 根據(jù)jira的要求進(jìn)行配置
default-storage-engine=INNODB
character_set_server=utf8mb4
innodb_default_row_format=DYNAMIC
innodb_large_prefix=ON
innodb_file_format=Barracuda
innodb_log_file_size=2G
重啟數(shù)據(jù)庫(kù)服務(wù)
[root@...wh2h6as05hZ... bin]# systemctl restart mysqld
4,Jira啟動(dòng)配置
4.1,配置Jira的數(shù)據(jù)庫(kù)鏈接
