openfire通过设置的方式跳过初始化部分

场景:

假如当前已经存在了openfire的数据库,并且该数据库和当前的openfire的版本没有变化。

如果重新启动了了一个没有初始化的openfire以后,不希望再进行数据库的初始化,方法如下:

我这边使用的openfire的版本为4.6.0,我使用的是源码版,若是安装版本,直接在安装目录下找到openfire.xml即可

1,找到

 

2,打开xml文件,将之前的xml中的内容复制过来,这里的前提是之前已经安装过openfire,并且可以找到该安装好的openfire.xml文件:

 

 

我这里用的mysql数据库

  <connectionProvider> 
    <className>org.jivesoftware.database.DefaultConnectionProvider</className> 
  </connectionProvider>  
  <database> 
    <defaultProvider> 
      <driver>com.mysql.cj.jdbc.Driver</driver>  
      <serverURL>jdbc:mysql://localhost:3306/openfire?rewriteBatchedStatements=true&amp;characterEncoding=UTF-8&amp;characterSetResults=UTF-8&amp;serverTimezone=UTC</serverURL>  
      <username encrypted="true">f7cb6a1db5b0a00cdc6a49dae748e49974ee9b4ec62cea27</username>  
      <password encrypted="true">ca8f5784eea2a8b628c2c140aa873c7914baedb5a7cdabc1</password>  
      <testSQL>select 1</testSQL>  
      <testBeforeUse>false</testBeforeUse>  
      <testAfterUse>false</testAfterUse>  
      <testTimeout>500</testTimeout>  
      <timeBetweenEvictionRuns>30000</timeBetweenEvictionRuns>  
      <minIdleTime>900000</minIdleTime>  
      <maxWaitTime>500</maxWaitTime>  
      <minConnections>5</minConnections>  
      <maxConnections>25</maxConnections>  
      <connectionTimeout>1.0</connectionTimeout> 
    </defaultProvider> 
  </database>  
  <setup>true</setup>  
  <fqdn>127.0.0.1</fqdn> 

 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

追风筝的Coder

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值