powered by Jive Software

MySQL DB openfire OS Debian

MariaDB [openfire]> source /usr/share/openfire/resources/database/openfire_mysql.sql;
ERROR 1071 (42000) at line 119 in file: ‘/usr/share/openfire/resources/database/openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
ERROR 1071 (42000) at line 127 in file: ‘/usr/share/openfire/resources/database/openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
ERROR 1071 (42000) at line 143 in file: ‘/usr/share/openfire/resources/database/openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
ERROR 1071 (42000) at line 163 in file: ‘/usr/share/openfire/resources/database/openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
ERROR 1146 (42S02) at line 372 in file: ‘/usr/share/openfire/resources/database/openfire_mysql.sql’: Table ‘openfire.ofMucService’ doesn’t exist

MariaDB [openfire]> show tables;
±---------------------+
| Tables_in_openfire |
±---------------------+
| mucextinfo |
| ofBookmark |
| ofConParticipant |
| ofConversation |
| ofExternalServices |
| ofGroup |
| ofGroupProp |
| ofGroupUser |
| ofID |
| ofMessageArchive |
| ofMucAffiliation |
| ofMucConversationLog |
| ofMucMember |
| ofMucRoom |
| ofMucRoomProp |
| ofMucServiceProp |
| ofOffline |
| ofPresence |
| ofPrivacyList |
| ofProperty |
| ofPubsubAffiliation |
| ofPubsubDefaultConf |
| ofPubsubItem |
| ofPubsubNode |
| ofPubsubNodeGroups |
| ofPubsubNodeJIDs |
| ofPubsubSubscription |
| ofPushNotiService |
| ofRRDs |
| ofRoster |
| ofRosterGroups |
| ofSecurityAuditLog |
| ofUser |
| ofUserFlag |
| ofUserProp |
| ofVCard |
| ofVersion |
±---------------------+

Due to the fact that this Table 'openfire.ofMucService’is missing Some errors pop up. For example, you don’t create a service or switch to the room administrator. I think a lot of errors with plugins where this table appears.
Please help me create this table with all its parameters.

I seem to recall that someone posted earlier about using a specific character set or collate that caused this. I can’t find the original message though. What character set are you using? Can you try to use some alternatives?

I am running a script that comes with openfire. decided to check maybe something is missing. and found that at least one table is missing.
/usr/share/openfire/resources/database/openfire_mysql.sql

Is the table missing in the create script, or is the table missing in the database, after running the script?

I wrote in the beginning. I run the script I see errors. checked what tables are. as a result, the table was not created after applying the script

Try creating a database with a different character set or collate. That might help.

correctly I understand you need to create a new database and map

Created a new openfire1 database.
started the script
here is the result.
MariaDB [(none)]> use openfire1;
Database changed
MariaDB [openfire1]> source /usr/share/openfire/resources/database/openfire_mysq l.sql;
Query OK, 0 rows affected (0.03 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected, 1 warning (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

ERROR 1071 (42000) at line 119 in file: ‘/usr/share/openfire/resources/database/ openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
ERROR 1071 (42000) at line 127 in file: ‘/usr/share/openfire/resources/database/ openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
Query OK, 0 rows affected (0.00 sec)

ERROR 1071 (42000) at line 143 in file: ‘/usr/share/openfire/resources/database/ openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
Query OK, 0 rows affected (0.02 sec)

ERROR 1071 (42000) at line 163 in file: ‘/usr/share/openfire/resources/database/ openfire_mysql.sql’: Specified key was too long; max key length is 767 bytes
Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.02 sec)

Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.02 sec)

Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 0 rows affected (0.01 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

Query OK, 1 row affected (0.00 sec)

ERROR 1146 (42S02) at line 372 in file: ‘/usr/share/openfire/resources/database/ openfire_mysql.sql’: Table ‘openfire1.ofMucService’ doesn’t exist

openfire_mysql.sql (12.4 КБ)
/ usr / share / openfire / resources / database / openfire_mysq l.sql

What character set and collate options does your database use. Try changing it.

base called openfire. the base is configured on Mandriva OS debian9. I don’t quite understand you.

They character set and collation combination is defined here https://mariadb.com/kb/en/setting-character-sets-and-collations/

I seem to recall that someone else reported that using a different one made the error that you are reporting go away.

Yes, right, that’s exactly what happened to me. Messages disappeared. I did on this article
https://www.dmosk.ru/instruktions.php?object=openfire-ubuntu
I tried different java versions until I realized that there was a problem with the database

MariaDB [(none)]> SHOW CREATE DATABASE openfire;
±---------±---------------------------------------------------------------------+
| Database | Create Database |
±---------±---------------------------------------------------------------------+
| openfire | CREATE DATABASE openfire /*!40100 DEFAULT CHARACTER SET utf8mb4 */ |
±---------±---------------------------------------------------------------------+
1 row in set (0.00 sec)

Database for openfire the default character set should be used in Debian?

I came across an article. Fix it so it doesn’t break everything.
I).
1). CREATE DATABASE openfire CHARACTER SET utf8 COLLATE utf8_general_ci;

2). Or change the encoding of the current database:
use openfire;
alter database character set utf8;
alter database collate utf8_general_ci;
II). openfire.xml add a line


com.mysql.jdbc.Driver
………………

………………

true



III). you must specify it in the MySQL server settings in the [client] and [mysqld sections]

default-character-set = utf8

link to the article truth it is in Russian
http://mtaalamu.ru/blog/admining/1516.html
I’m waiting for you to correct the order of priority maybe you missed something.

Please specify in the documentation the requirements for the Linux operating system. version of Java. Requirements for databases namely encoding and so on.

Thank you for your efforts and your time!!!