Openfire修改Domain域值

版权声明:本文为博主chszs的原创文章,未经博主允许不得转载。 https://blog.csdn.net/chszs/article/details/48316845

Openfire修改Domain域值

作者:chszs,版权所有,未经同意,不得转载。博主主页:http://blog.csdn.net/chszs

与Tigase不同,Openfire安装后,它的配置属性不是写入XML文件中,而是基本上都存到数据库表里。
配置属性所在的数据表为ofProperty表

mysql> select * from ofProperty;
+--------------------------------------------+----------------------------------------------------------------------------------+
| name                                       | propValue                                                                        |
+--------------------------------------------+----------------------------------------------------------------------------------+
| adminConsole.port                          | 9090                                                                             |
| adminConsole.securePort                    | 9091                                                                             |
| connectionProvider.className               | org.jivesoftware.database.DefaultConnectionProvider                              |
| database.defaultProvider.connectionTimeout | 1.0                                                                              |
| database.defaultProvider.driver            | com.mysql.jdbc.Driver                                                            |
| database.defaultProvider.maxConnections    | 300                                                                              |
| database.defaultProvider.minConnections    | 10                                                                               |
| database.defaultProvider.password          | XXXXXXXXXXXXXXXXXXXXXX |
| database.defaultProvider.serverURL         | jdbc:mysql://XXX.XXX.XXX.XXX:3306/openfiredb?rewriteBatchedStatements=true           |
| database.defaultProvider.testAfterUse      | false                                                                            |
| database.defaultProvider.testBeforeUse     | false                                                                            |
| database.defaultProvider.testSQL           | select 1                                                                         |
| database.defaultProvider.username          | XXXXXXXXXXXXXXXXXXXXXX                                 |
| locale                                     | zh_CN                                                                            |
| locale.timeZone                            | Asia/Taipei                                                                      |
| passwordKey                                | XXXXXXXXXXXXXXXXXXXXXX                                                                 |
| provider.admin.className                   | org.jivesoftware.openfire.admin.DefaultAdminProvider                             |
| provider.auth.className                    | org.jivesoftware.openfire.auth.DefaultAuthProvider                               |
| provider.group.className                   | org.jivesoftware.openfire.group.DefaultGroupProvider                             |
| provider.lockout.className                 | org.jivesoftware.openfire.lockout.DefaultLockOutProvider                         |
| provider.securityAudit.className           | org.jivesoftware.openfire.security.DefaultSecurityAuditProvider                  |
| provider.user.className                    | org.jivesoftware.openfire.user.DefaultUserProvider                               |
| provider.vcard.className                   | org.jivesoftware.openfire.vcard.DefaultVCardProvider                             |
| setup                                      | true                                                                             |
| update.lastCheck                           | 1441615953135                                                                    |
| xmpp.auth.anonymous                        | true                                                                             |
| xmpp.domain                                | ubuntu                                                                           |
| xmpp.session.conflict-limit                | 0                                                                                |
| xmpp.socket.ssl.active                     | true                                                                             |
+--------------------------------------------+----------------------------------------------------------------------------------+
29 rows in set (0.00 sec)

可见,domain域的配置见xmpp.domain这一行。
修改它的值即可。

mysql> update ofProperty set propValue='XXX.com' where name='xmpp.domain';

但是要注意,要让修改后的domain域生效,需要重启Openfire服务器。

# cd /opt/openfire/
# ./bin/openfire restart
Shutting down openfire
Stopped.
Restarting openfire

此时可以用XMPP客户端进行验证,OK!

上一篇:从企业钉钉的接口获取数据


下一篇:某企业虚拟化平台时间同步异常排查