首页 > 系统相关 >centos 7.9搭建安装confluence-7

centos 7.9搭建安装confluence-7

时间:2023-04-07 17:00:21浏览次数:59  
标签:wiki centos atlassian 7.19 confluence mysql 7.9 root

centos 7.9搭建安装confluence-7

1、安装Java环境

1.1 解压tar包

[root@wiki ~]# tar xf jdk-8u171-linux-x64.tar.gz -C /usr/local/
[root@wiki ~]# mv /usr/local/jdk1.8.0_171 /usr/local/jdk

1.2 配置java环境变量

# 配置java环境变量
[root@wiki ~]# sed -i.ori '$a export JAVA_HOME=/usr/local/jdk\nexport PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH\nexport CLASSPATH=.$CLASSPATH:$JAVA_HOME/lib:$JAVA_HOME/lib/tools.jar' /etc/profile

[root@wiki ~]# tail -3 /etc/profile
export JAVA_HOME=/usr/local/jdk
export PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH
export CLASSPATH=.$CLASSPATH:$JAVA_HOME/lib:$JAVA_HOME/lib/tools.jar

# 使环境变量立刻生效
[root@wiki ~]# source /etc/profile

1.3 检查java是否安装成功

#检查java是否安装成功
[root@wiki ~]# java -version
java version "1.8.0_171"
Java(TM) SE Runtime Environment (build 1.8.0_171-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)

2、安装Confluence

官方链接:Confluence Server 下载存档 | Atlassian

2.1 创建安装目录

# 下载Confluence包
[root@wiki ~]# wget https://www.atlassian.com/software/confluence/downloads/binary/atlassian-confluence-7.19.7.tar.gz

# 创建安装目录
[root@wiki ~]# mkdir -p /data/wiki/confluence

# 解压缩
[root@wiki ~]# tar xf atlassian-confluence-7.19.7.tar.gz -C /data/wiki/confluence/
 
[root@wiki ~]# cd /data/wiki/confluence/
[root@wiki confluence]# ll
总用量 0
drwxr-xr-x 12 1000 1000 314 3月  21 14:02 atlassian-confluence-7.19.7

2.2 配置数据目录

[root@wiki confluence]# vim atlassian-confluence-7.19.7/confluence/WEB-INF/classes/confluence-init.properties

[root@wiki confluence]# tail -1 atlassian-confluence-7.19.7/confluence/WEB-INF/classes/confluence-init.properties 
confluence.home=/data/wiki/confluence

2.3 启动confluence

# 启动confluence
[root@wiki confluence]# cd atlassian-confluence-7.19.7/bin/
[root@wiki bin]# ./start-confluence.sh 

To run Confluence in the foreground, start the server with start-confluence.sh -fg
executing as current user
If you encounter issues starting up Confluence, please see the Installation guide at http://confluence.atlassian.com/display/DOC/Confluence+Installation+Guide

Server startup logs are located in /data/wiki/confluence/atlassian-confluence-7.19.7/logs/catalina.out
---------------------------------------------------------------------------
Using Java: /usr/local/jdk/bin/java
2023-04-07 15:03:38,779 INFO [main] [atlassian.confluence.bootstrap.SynchronyProxyWatchdog] A Context element for ${confluence.context.path}/synchrony-proxy is found in /data/wiki/confluence/atlassian-confluence-7.19.7/conf/server.xml. No further action is required
---------------------------------------------------------------------------
Using CATALINA_BASE:   /data/wiki/confluence/atlassian-confluence-7.19.7
Using CATALINA_HOME:   /data/wiki/confluence/atlassian-confluence-7.19.7
Using CATALINA_TMPDIR: /data/wiki/confluence/atlassian-confluence-7.19.7/temp
Using JRE_HOME:        /usr/local/jdk
Using CLASSPATH:       /data/wiki/confluence/atlassian-confluence-7.19.7/bin/bootstrap.jar:/data/wiki/confluence/atlassian-confluence-7.19.7/bin/tomcat-juli.jar
Using CATALINA_OPTS:   -Datlassian.plugins.startup.options='' -Dorg.apache.tomcat.websocket.DEFAULT_BUFFER_SIZE=32768 -Dconfluence.context.path= -Djava.locale.providers=JRE,SPI,CLDR -Dsynchrony.enable.xhr.fallback=true -Datlassian.plugins.enable.wait=300 -Djava.awt.headless=true -Xloggc:/data/wiki/confluence/atlassian-confluence-7.19.7/logs/gc-2023-04-07_15-03-38.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=2M -Xlog:gc+age=debug:file=/data/wiki/confluence/atlassian-confluence-7.19.7/logs/gc-2023-04-07_15-03-38.log::filecount=5,filesize=2M -XX:G1ReservePercent=20 -XX:+UseG1GC -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDateStamps -XX:+IgnoreUnrecognizedVMOptions -XX:ReservedCodeCacheSize=256m -Xms1024m -Xmx1024m 
Using CATALINA_PID:    /data/wiki/confluence/atlassian-confluence-7.19.7/work/catalina.pid
Tomcat started.
# 检查端口是否成功启动
[root@wiki bin]# netstat -nltp | grep 8090
tcp6       0      0 :::8090                 :::*                    LISTEN      8783/java     

[root@wiki bin]# lsof -i:8090
COMMAND  PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
java    8783 root   56u  IPv6  30231      0t0  TCP *:8090 (LISTEN)

3、安装MySQL

下载地址:MySQL :: Download MySQL Community Server

3.1 下载MySQL包

# 卸载系统自带mariadb-libs
[root@wiki ~]# yum -y remove mysql-libs

# 安装依赖包
[root@wiki ~]# yum -y install net-tools libaio

# 下载MySQL包
[root@wiki ~]# wget https://downloads.mysql.com/archives/get/p/23/file/mysql-8.0.28-1.el7.x86_64.rpm-bundle.tar

3.2 解压、安装mysql

# 解压
[root@wiki ~]# tar xf mysql-8.0.28-1.el7.x86_64.rpm-bundle.tar

# 批量安装rpm包
[root@wiki ~]# yum -y install *

3.3 初始化数据库

[root@wiki ~]# mysqld --initialize --user=mysql
[root@wiki ~]# mysqld --initialize-insecure --user=mysql

4、启动mysql

# 启动mysql
[root@wiki ~]# systemctl start mysqld

# 查看mysql状态
[root@wiki ~]# systemctl status mysqld | grep active
   Active: active (running) since 五 2023-04-07 15:24:36 CST; 19s ago

# 查看mysql端口是否成功启动
[root@wiki ~]# netstat -nltp | grep 3306
tcp6       0      0 :::3306                 :::*                    LISTEN      9127/mysqld         
tcp6       0      0 :::33060                :::*                    LISTEN      9127/mysqld  

# 查看mysql版本
[root@wiki ~]# mysql --version
mysql  Ver 8.0.28 for Linux on x86_64 (MySQL Community Server - GPL)

5、安装驱动

驱动下载:Download mysql JAR files with all dependencies

我这里mysql是8.0.28版本,所以驱动也是选的8.0.28

5.1 下载驱动

下载之后解压把jar包移入/data/wiki/confluence/atlassian-confluence-7.19.7/confluence/WEB-INF/lib目录下

[root@wiki ~]# mv mysql-connector-java-8.0.28.jar /data/wiki/confluence/atlassian-confluence-7.19.7/confluence/WEB-INF/lib/

5.2 修改mysql配置

[root@wiki ~]# vim /etc/my.cnf
[root@wiki ~]# egrep -v "^#|^$" /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock

log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

init-connect ='SET NAMES utf8'
bind-address = 127.0.0.1
port = 3306
innodb_file_per_table=1
 
#confluence
character-set-server=utf8mb4
collation-server=utf8mb4_bin
default-storage-engine=INNODB
max_allowed_packet=256M
innodb_log_file_size=2GB
transaction-isolation=READ-COMMITTED
binlog_format=row

[client]
port = 3306
socket = /var/lib/mysql/mysql.sock
default-character-set = utf8mb4

5.3 重启mysql

[root@wiki ~]# systemctl restart mysqld

5.4 修改密码

# 查看临时密码
[root@wiki ~]# cat /var/log/mysqld.log|grep localhost
2023-04-07T07:58:04.962926Z 6 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: )M(M+ClSU7LT
# 修改密码
[root@wiki ~]# mysql -uroot -p
Enter password: 
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.28

Copyright (c) 2000, 2022, Oracle and/or its affiliates.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> alter user 'root'@'localhost' identified by '123456';
Query OK, 0 rows affected (0.01 sec)

mysql> 

5.5 创建confluence数据库、创建对应账户并授权

mysql> CREATE DATABASE confluence CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
Query OK, 1 row affected (0.00 sec)

mysql> create user 'confluenceuser'@'localhost' IDENTIFIED BY 'xxx';
Query OK, 0 rows affected (0.01 sec)

mysql> grant all privileges on confluence.* TO 'confluenceuser'@'localhost' with grant option;
Query OK, 0 rows affected (0.00 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

6、配置web

6.1 打开web页面 ,进入系统安装页面。

6.2 选择语言:中文

image.png-85kB

6.3 记录服务器ID

image.png-32.7kB

6.4 下载破解程序并上传

# 下载破解程序
[root@wiki ~]# wget https://github.com/haxqer/confluence/releases/download/v1.3.3/atlassian-agent.jar
 
# 把agent加入到Java中
[root@wiki ~]# echo 'export JAVA_OPTS="-javaagent:/root/atlassian-agent.jar ${JAVA_OPTS}"' >> /root/.bashrc 

# 需要重启confluence
[root@wiki ~]# cd /data/wiki/confluence/atlassian-confluence-7.19.7/bin/

[root@wiki bin]# ./stop-confluence.sh 
[root@wiki bin]# ./start-confluence.sh

#检查是否有agent参数
[root@wiki ~]# ps aux|grep java |grep agent
root       9957  167 22.4 4385956 866876 pts/2  Sl   16:29   0:10 /usr/local/jdk/bin/java -Djava.util.logging.config.file=/data/wiki/confluence/atlassian-confluence-7.19.7/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -javaagent:/root/atlassian-agent.jar .....
# 服务器ID 
# 执行破解,获得授权码
[root@wiki ~]# java -jar atlassian-agent.jar -p conf -m [email protected] -n zhile -o https://zhile.io -s BY4Q-R4C1-E3PP-7U4C

====================================================
=======     Atlassian Crack Agent v1.3.1     =======
=======           https://zhile.io           =======
=======          QQ Group: 30347511          =======
====================================================

Your license code(Don't copy this line!!!): 

AAABgA0ODAoPeJxtUd1yojAYvc9TMLOXHZSAgutMZtYGdN0VtbV0dy9D/JSMEJgkauHpi0hvtr3MOZPz932bK2HNKmU5gYX9qedMx9iiuxfLdVwPUQXMiFKGzAC5IbYzsp0ARReWnzuGHFiuAYWguRJVhyQyF4UwsLdywUFqsNLayoyp9HQ4bDKRw0CUaKOOTAp9F/nE8lIeBowbcQFi1BkQLaVp31HMRE6apvmRpumAlwXqPX4ynZGYXul8Pvx1DIu368zNm3113YvH+IQXY5z8TmbZk1nsa+91GOZpRE/8T82r+m/0sKALeSTkbrszTBlQfbMOWt1NXuoK1qwAQjdxHD3T5WyF2kDSgGSSQ/RWCVX3W02+t0Pdtur/LkOyWoa7aG2vsD9xJmPfHWMc+GgH6gKqpR//jZ7s5xHFduRtt3aQjCg6Qf0KSt82wr7jBM7E8/CH5Nd+27PiGdPw/836oT7k3Huz9blIQW0OiW5xYmPUJiRfpOz379p3V3oHIIe4XjAtAhUAg3WSxP8sqjOVUXaNtUw7ttWN4zQCFA4LJWko8V5bM5M9uMFudFYZT3DoX02im

6.5 生成激活码输入然后下一步

image.png-77.3kB

6.6 选择自己的数据库

image.png-72.7kB

6.7 输入相关数据库信息

image.png-72.5kB

image.png-89.9kB

6.8 设置管理员账户信息(ywb97!!08)

image.png-84.5kB

image.png-43.8kB

image.png-21.5kB

这样就可以愉悦的玩耍了,其他功能请自行探索
image.png-87.1kB

标签:wiki,centos,atlassian,7.19,confluence,mysql,7.9,root
From: https://www.cnblogs.com/ywb123/p/17296740.html

相关文章

  • Centos7 安装 maven3.6.3
    1.下载maven3.6.3安装包wgethttps://mirrors.ocf.berkeley.edu/apache/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz--no-check-certificate2.创建一个安装maven的目录mkdir/usr/local/maven3.解压下载的软件包tar-zxvfapache-maven-3.6.3-bi......
  • Centos 7 安装 rabbitmq
    1.配置yum下载源:yuminstallepel-release-y2.下载rabbitmq:yuminstallrabbitmq-server-y3.配置webui网页插件(网页登陆端口号:15672)rabbitmq-pluginsenablerabbitmq_management4.启动rabbitmq-serversystemctlstartrabbitmq-server5.查看RabbitMq运行状态:......
  • Centos 7 yum 安装redis
    一、安装redis1、检查是否有redis yum 源yumlist|grepredis2、下载fedora的epel仓库yuminstallepel-release-y3、安装redis数据库yuminstallredis-y4.防火墙开放相应端口iptables-IINPUT-ptcp--dport6379-jACCEPT5.修改综合设置(用户名,密码,......
  • Centos8 配置本地yum源
    Centos8配置本地yum源centos8发行版通过BaseOS和应用流(AppStream)仓库发布,这篇文章主要介绍了CentOS8配置本地yum源的详细教程,需要的朋友可以参考下centos8发行版通过BaseOS和应用流(AppStream)仓库发布,AppStream是对传统rpm格式的全新扩展,为一个组件同时提供多个......
  • centos6更换源
    #备份原有文件[root@zk1/]#mv/etc/yum.repos.d/CentOS-Base.repo/etc/yum.repos.d/CentOS-Base.repo.backup#跳过检查证书,从https://www.xmpan.com/Centos-6-Vault-Aliyun.repo下载源[root@zk1/]#wget--no-check-certificate/etc/yum.repos.d/CentOS-Base.repohttps://w......
  • CentOS7安装zabbix-agent
    一:系统要求1.centos72.zabbix服务器端5.0版本 二:安转和配置zabbix1.安装zabbix存储库#rpm-Uvhhttps://repo.zabbix.com/zabbix/5.0/rhel/7/x86_64/zabbix-release-5.0-1.el7.noarch.rpm#yumcleanall2.安装zabbix代理#yuminstallzabbix-agent3.启动zabb......
  • Centos7 安装配置FTP服务
    1、FTP简介ftp(FileTransferProtocol文件传输协议)是基于TCP/IP协议的应用层协议,用于文件的传输,包括ftp服务器(或服务端)和ftp客户端2、关闭防火墙设置selinuxsystemcltstopfirewalld.service&&systemcltdisablefirewalld.serviceSELINUX=disabledsetenforce0使修改立......
  • Centos7使用systemctl管理mysql8服务开机启动
    centos7下开机默认不执行原来配置启动命令的/etc/rc.local文件,建议使用systemctl管理自启动服务,如果要使用/etc/rc.local进行自启动,需要给文件/etc/rc.d/rc.local添加可执行权限。    systemctl常用命令如下:1.列出所有启动项命令systemctllist-unit-files开启的和未开启的......
  • Linux(CentOS7) c语言编程, 多线程入栈出栈,错误:expected ‘while’ before ‘int’
    在Centos7里,编写多线程的入栈出栈时,出现这样错误提示:图片版: 文字版:[root@CentOs705-xitongbiancheng]#gcc05-24-01.pthread-cancel-pop-push.c-pthread05-24-01.pthread-cancel-pop-push.c:在函数‘func’中:05-24-01.pthread-cancel-pop-push.c:47:1:错误:expected......
  • Centos7安装docker
    1、查看系统版本,系统内核3.10以上并卸载旧版本。yumremovedocker\docker-client\docker-client-latest\docker-common\docker-latest\docker-latest-logrotate\docker-logrotate\docker-engine 2、docker安装安装yum-utils......