与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;
但是要注意,要让修改后的domain域生效,需要重启Openfire服务器。
# cd /opt/openfire/
# ./bin/openfire restart
Shutting down openfire
Stopped.
Restarting openfire
此时可以用XMPP客户端进行验证,OK!
--------------------------------------分割线 --------------------------------------
CentOS下Openfire详细安装过程
CentOS 5.4下基于Jabber/XMPP协议的Openfire服务器配置笔记
--------------------------------------分割线 --------------------------------------