1.安装java环境
yum -y install java-1.8.0-openjdk-1.8.0.272.b10-1.el7_9.x86_64
2.安装Mysql5.7数据库
rpm -ivh https://dev.mysql.com/get/mysql80-community-release-el7-3.noarch.rpm
vim /etc/yum.repos.d/mysql-community.repo
//修改 mysql-community.repo 将MySQL8.0的enable=1修改成enable=0
//将MySQL5.7的enable=1修改成enable=1
yum install mysql-server -y
//启动并设置设置开机自启动:
systemctl restart mysqld
systemctl enable mysqld
//安装完成后,root密码保存在日志文件中
grep password /var/log/mysqld.log
mysql -uroot -p'密码'
alter user root@localhost identified by '新密码';
//修改root密码
create database confluence default character set utf8 collate utf8_bin;
grant all on confluence.* to 'confluencer'@'%' identified by '密码';
//创建授权用户
flush privileges
////////数据库优化的配置文件,编辑后重启mysqld
//企业中正用的优化数据
//在默认的/etc/my.cnf中最后直接添加这些参数就可以
port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
#lc-messages-dir = /usr/share/mysql
#skip-external-locking
#bind-address = 0.0.0.0
thread_stack = 192K
thread_cache_size = 8
log_error = /var/log/mysqlerror.log
expire_logs_days = 10
max_binlog_size = 100M
skip-name-resolve
back_log = 600
max_connections = 1000
open_files_limit = 65535
table_open_cache = 128
binlog_cache_size = 1M
max_heap_table_size = 8M
tmp_table_size = 16M
read_buffer_size = 2M
read_rnd_buffer_size = 8M
sort_buffer_size = 8M
join_buffer_size = 8M
thread_cache_size = 8
query_cache_size = 16M
query_cache_limit = 2M
key_buffer_size = 32M
transaction-isolation=READ-COMMITTED
innodb_large_prefix=on
innodb_file_format=Barracuda
character-set-server=utf8mb4
collation-server=utf8mb4_bin
default-storage-engine=INNODB
max_allowed_packet=256M
innodb_log_file_size=2GB
binlog_format=row
slow_query_log=on
slow_query_log_file=/var/log/mysql-slow.log
3.安装confluence
chmod +x atlassian-confluence-7.4.6-x64.bin
//执行安装:
./atlassian-confluence-7.4.6-x64.bin
安装过程中confluence进行一些初始化配置
第一问:
This will install Confluence 7.4.6 on yourcomputer.
OK [o, Enter], Cancel [c]
//允许程序安装,输入回车键
第二问:
Choose the appropriate installation or upgradeoption.
Please choose one of the following:Express Install (uses default settings) [1],
Custom Install (recommended for advanced users)[2, Enter],
Upgrade an existing Confluenceinstallation [3]
三个选项的含义分别是快速安装(默认设置)、自定义安装(适合高级用户)、默认设置进行安装;
第三问:
See where Confluence will be installed and thesettings that will be used.
Installation Directory: /opt/atlassian/confluence
Home Directory: /var/atlassian/applicationdata/confluence
HTTP Port: 8090
RMI Port: 8000
Install as service: Yes
Install [i, Enter], Exit [e]
默认安装路径是/opt/atlassian/confluence
默认路径是/var/atlassian/application-data/confluence
默认监听端口是HTTP Port: 8090 RMI Port: 8000
安装成功
是否现在启动confluence,选择n
4.破解
1)在/opt/atlassian/confluence/confluence/WEB-INF/lib目录中找到atlassian-extras-decoder-v2-3.4.1.jar并备份
2)随后将atlassian-extras-decoder-v2-3.4.1.jar重命名为atlassian-extras-2.4.jar并下载到本地 (和破解工具放在同一目录)
3)点击.patch!选择上一步保存到本地的要破解的jar包atlassian-extras-2.4.jar,最后点击打开破解完成。不要关闭破解工具页面,后面还会用到。
4)将已被破解的jar包atlassian-extras-2.4.jar重名为atlassian-extras-decoder-v2-3.4.1.jar并放置在原路径/opt/atlassian/confluence/confluence/WEB-INF/lib
5)下载mysq连接驱动jar包mysql-connector-java-5.1.24-bin.jar并上传至/opt/atlassian/confluence/confluence/WEB-INF/lib目录
wget https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.24/mysql-connector-java-5.1.24.jar
5.启动
/opt/atlassian/confluence/bin/startup.sh
选择语言
选择产品
不选应用,点击下一步
复制服务器ID,粘贴到破解工具
Name随便输入6位数,点击gen生成Key,直接复制到网页
选择自己数据库
数据库连接成功