[root@vm1 ~]# tail -13 /etc/my.cnf
character-set-server=utf8
collation-server=utf8_bin
default-storage-engine=INNODB
max_allowed-packet=34M
sql_mode=ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
innodb_log_file_size=256M
init_connect=‘SET collation_connection = utf8_unicode_ci‘
init_connect=‘SET NAMES utf8‘
[client]
default-character-set=utf8
[mysql]
default-character-set=utf8
[root@vm1 ~]#
重启mysqld服务,并创建confluence使用的库及授权相关用户:
[root@vm1 ~]# systemctl restart mysqld
[root@vm1 ~]# mysql -p
mysql> create database confluence character set utf8 collate utf8_bin;
Query OK, 1 row affected (0.00 sec)
mysql> grant all on confluence.* to ‘confluenceAdmin‘@‘192.%‘ identified by ‘Inspiry@2018‘;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)
mysql> \q
Bye
[root@vm1 ~]#
安装atlassian-confluence
[root@vm2 confluence]# ls
atlassian-confluence-6.3.1-x64.bin
atlassian-extras-decoder-v2-3.2.jar
atlassian-universal-plugin-manager-plugin-2.22.jar
[root@vm2 confluence]# chmod +x atlassian-confluence-6.3.1-x64.bin
[root@vm2 confluence]# ./atlassian-confluence-6.3.1-x64.bin
Unpacking JRE ...
Starting Installer ...
This will install Confluence 6.3.1 on your computer.
OK [o, Enter], Cancel [c]
o
Choose the appropriate installation or upgrade option.
Please choose one of the following:
Express Install (uses default settings) [1],
Custom Install (recommended for advanced users) [2, Enter],
Upgrade an existing Confluence installation [3]
1
See where Confluence will be installed and the settings that will be used.
Installation Directory: /opt/atlassian/confluence
Home Directory: /var/atlassian/application-data/confluence
HTTP Port: 8090
RMI Port: 8000
Install as service: Yes
Install [i, Enter], Exit [e]
i
Extracting files ...
Please wait a few moments while we configure Confluence.
Installation of Confluence 6.3.1 is complete
Start Confluence now?
Yes [y, Enter], No [n]
y
Please wait a few moments while Confluence starts up.
Launching Confluence ...
Installation of Confluence 6.3.1 is complete
Your installation of Confluence 6.3.1 is now ready and can be accessed via
your browser.
Confluence 6.3.1 can be accessed at http://localhost:8090
Finishing installation ...
[root@vm2 confluence]# lsof -i:8090
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 24169 confluence 36u IPv6 1465531 0t0 TCP *:8090 (LISTEN)
[root@vm2 confluence]# lsof -i:8000
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 24169 confluence 54u IPv6 1466046 0t0 TCP localhost:irdmi (LISTEN)
[root@vm2 confluence]#
通过以上可以看出confluence安装到了/opt/atlassian/confluence和/var/atlassian/application-data/confluence目录下,并且confluence默认监听的端口是8090.一路默认安装即可!
注意:confluence的主要配置文件为/opt/atlassian/confluence/conf/server.xml,和jira类似。此server.xml相当于tomcat中的server.xml配置文件,如果要修改访问端口,可以这里修改。
如果要修改confluence的数据目录,可以在安装的时候,在安装过程中进行更换(默认是/var/atlassian/application-data/confluence)
设置firewalld 开放相关port
[root@vm2 confluence]# firewall-cmd --zone=public --add-port=8090/tcp --permanent
success
[root@vm2 confluence]# firewall-cmd --zone=public --add-port=8000/tcp --permanent
success
[root@vm2 confluence]# firewall-cmd --reload
success
[root@vm2 confluence]#
在浏览器中输入confluence的地址及port,访问如下所示:
根据向导安装产品,如下所示:
然后系统服务server _Id 并需要用户输入 授权码,如下所示:
接下来需要破解confluence,首先停止confluence服务,如下所示:
[root@vm2 confluence]# /etc/init.d/confluence stop
executing using dedicated 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 /opt/atlassian/confluence/logs/catalina.out
---------------------------------------------------------------------------
Using Java: /opt/atlassian/confluence/jre//bin/java
2018-05-03 17:31:28,470 INFO [main] [atlassian.confluence.bootstrap.SynchronyProxyWatchdog] A Context element for ${confluence.context.path}/synchrony-proxy is found in /opt/atlassian/confluence/conf/server.xml. No further action is required
---------------------------------------------------------------------------
Using CATALINA_BASE: /opt/atlassian/confluence
Using CATALINA_HOME: /opt/atlassian/confluence
Using CATALINA_TMPDIR: /opt/atlassian/confluence/temp
Using JRE_HOME: /opt/atlassian/confluence/jre/
Using CLASSPATH: /opt/atlassian/confluence/bin/bootstrap.jar:/opt/atlassian/confluence/bin/tomcat-juli.jar
Using CATALINA_PID: /opt/atlassian/confluence/work/catalina.pid
Tomcat stopped.
[root@vm2 confluence]#
[root@vm2 ~]# sz /opt/atlassian/confluence/confluence/WEB-INF/lib/atlassian-extras-decoder-v2-3.2.jar
从/opt/atlassian/confluence/confluence/WEB-INF/lib中,拷贝atlassian-extras-decoder-v2- 3.2.jar到windows,并重命名为atlassian-extras-2.4.jar。
在windows下,生成License Key。
1)cmd 中执行: java -jar confluence_keygen.jar,如下所示
2)然后把上面保存的Server ID(服务器ID)粘贴进去,然后点击“.gen!”,保存生成的key,如下所示:
3)打补丁。点击“.patch!”,选择第2步中重命名的atlassian-extras-2.4.jar,会生成新的atlassian-extras-2.4.jar,旧的jar包会被改为.bak。
4)将新的atlassian-extras-2.4.jar和mysql-connector-java-5.1.39-bin.jar到/opt/atlassian/confluence/confluence/WEB-INF/lib,并且删除旧的atlassian-extras-decoder-v2-3.2.jar。
[root@vm2 ~]# rz (接收破解后的atlassian-extras-2.4.jar文件)
[root@vm2 ~]# cp atlassian-extras-2.4.jar /opt/atlassian/confluence/confluence/WEB-INF/lib/
[root@vm2 ~]# rm -f /opt/atlassian/confluence/confluence/WEB-INF/lib/atlassian-extras-decoder-v2-3.2.jar
[root@vm2 ~]# cp mysql-connector-java-5.1.39-bin.jar /opt/atlassian/confluence/confluence/WEB-INF/lib/
启动confluence
[root@vm2 confluence]# /etc/init.d/confluence start
To run Confluence in the foreground, start the server with start-confluence.sh -fg
executing using dedicated user: confluence
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 /opt/atlassian/confluence/logs/catalina.out
---------------------------------------------------------------------------
Using Java: /opt/atlassian/confluence/jre//bin/java
2018-05-03 17:34:36,954 INFO [main] [atlassian.confluence.bootstrap.SynchronyProxyWatchdog] A Context element for ${confluence.context.path}/synchrony-proxy is found in /opt/atlassian/confluence/conf/server.xml. No further action is required
---------------------------------------------------------------------------
Using CATALINA_BASE: /opt/atlassian/confluence
Using CATALINA_HOME: /opt/atlassian/confluence
Using CATALINA_TMPDIR: /opt/atlassian/confluence/temp
Using JRE_HOME: /opt/atlassian/confluence/jre/
Using CLASSPATH: /opt/atlassian/confluence/bin/bootstrap.jar:/opt/atlassian/confluence/bin/tomcat-juli.jar
Using CATALINA_PID: /opt/atlassian/confluence/work/catalina.pid
Tomcat started.
[root@vm2 confluence]# lsof -i:8090
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
java 24442 confluence 36u IPv6 1468808 0t0 TCP *:8090 (LISTEN)
[root@vm2 confluence]#
接下来回到浏览器 ,选择数据库类型,如下所示:
然后配置数据库,如下所示:
设置mysql的jdbc ,如下所示:
选择空白站点,如下所示:
配置用户管理,如下所示:
配置管理密码,如下所示:
创建空间,以存储内容:
查看授权的详细信息:点击一般设置-->管理-->授权细节,可以查看license信息。
原文地址:http://blog.51cto.com/caiyuanji/2115500