Project

General

Profile

Bug #8554

[MySQL] Sometimes setting version via property doesn't work (without error)

Added by felix liang 3 months ago. Updated 2 months ago.

Status:
Closed
Priority:
Normal
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Database:
n/a
Applicable version:
7.1.3
Source Code Disclaimer:

Description

Hi Tigase team

We are Sytac Limted and we are testing tigase to put this to production in very future.
We are using "java -jar tigase-server-7.1.5-b4512.jar" to install tigase 7.1.5 .
And following the guide step by step. No error occurs during the installation.

While i run "./scripts/tigase.sh start etc/tigase.conf "
From logs/tigase-console.log

=====================tigase-console.log=========================
Please upgrade database schema now.
Current scheme version is: null, expected: 7.1
Check the schema upgrade guide at the address:
Administration Guide > Tigase Server Schema v7.1 Updates (available locally in docs directory and online http://docs.tigase.org)
----
If you have upgraded your schema and you are still
experiencing this problem please contact support at
e-mail address: support@tigase.org
=====================tigase-console.log=========================

I searched the forum and found the following bug very similar to my case.

https://tigase.tech/issues/6753

This bug provide a workaround for this kind of issue ,execute following command should be work.
mysql_upgrade -u root -p --force

After i execute the upper command . It still gives following error.

Here is the init.properties i am using now:

=========================init.properties==============================
--comp-class-1 = tigase.muc.MUCComponent
--virt-hosts = tig-cet.testpurpose.com
--auth-db-uri = jdbc:mysql://127.0.0.1/tigasecetdb?user=tigasecet&password=Syntac%40019
--user-db-uri = jdbc:mysql://127.0.0.1/tigasecetdb?user=tigasecet&password=Syntac%40019
--user-db = mysql
--admins = admin@tig-cet.testpurpose.com
--comp-name-6 = message-archive
--comp-name-5 = http
--comp-name-4 = stun
--auth-db = tigase-auth
--comp-name-3 = proxy
config-type = --gen-config-def
--comp-name-2 = pubsub
--comp-name-1 = muc
--cluster-mode = false
--sm-plugins = +message-archive-xep-0136,+jabber:iq:auth,+urn:ietf:params:xml:ns:xmpp-sasl,+urn:ietf:params:xml:ns:xmpp-bind,+urn:ietf:params:xml:ns:xmpp-session,+jabber:iq:register,+jabber:iq:roster,+presence,+jabber:iq:privacy,+jabber:iq:version,+http://jabber.org/protocol/stats,+starttls,+msgoffline,+vcard-temp,+http://jabber.org/protocol/commands,+jabber:iq:private,+urn:xmpp:ping,+basic-filter,+domain-filter,+pep,+zlib
--comp-class-6 = tigase.archive.MessageArchiveComponent
--debug = server,xmpp.impl,db
--comp-class-5 = tigase.http.HttpMessageReceiver
--comp-class-4 = tigase.stun.StunComponent
--comp-class-3 = tigase.socks5.Socks5ProxyComponent
--comp-class-2 = tigase.pubsub.PubSubComponent
======================init.properties=============================

Here is the tigase.conf

=======================tigase.conf============================
#osgiEnabled=(true|false)
#osgiEnabled=false
OSGI=false
ENC="-Dfile.encoding=UTF-8 -Dsun.jnu.encoding=UTF-8"
DRV="-Djdbc.drivers=com.mysql.jdbc.Driver"
#DRV="-Djdbc.drivers=com.mysql.jdbc.Driver:org.postgresql.Driver:org.apache.derby.jdbc.EmbeddedDriver"
#GC="-XX:+UseBiasedLocking -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -XX:NewRatio=2 -XX:+CMSIncrementalMode -XX:ParallelCMSThreads=2 -XX:-ReduceInitialCardMarks -XX:CMSInitiatingOccupancyFraction=70  -XX:+UseCMSInitiatingOccupancyOnly"
#EX="-XX:+OptimizeStringConcat -XX:+DoEscapeAnalysis -XX:+UseNUMA"

#GC_DEBUG=" -XX:+PrintTenuringDistribution -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -Xloggc:logs/jvm.log -verbose:gc "

#JMX_REMOTE_IP="-Djava.rmi.server.hostname=0.0.0.0"

#DNS_RESOLVER=" -Dresolver-class=tigase.util.DNSResolverDefault "
#INTERNAL_IP=" -Dtigase-primary-address=hostname.local "
#EXTERNAL_IP=" -Dtigase-secondary-address=hostname "

JAVA_HOME="/usr/jdk"
CLASSPATH=""
#PRODUCTION_HEAP_SETTINGS=" -Xms5G -Xmx5G " # heap memory settings must be adjusted on per deployment-base!
JAVA_OPTIONS="${GC} ${GC_DEBUG} ${EX} ${ENC} ${DRV} ${JMX_REMOTE_IP} -server ${PRODUCTION_HEAP_SETTINGS} ${DNS_RESOLVER} ${INTERNAL_IP} ${EXTERNAL_IP}  -XX:MaxDirectMemorySize=128m "
TIGASE_OPTIONS=" --property-file etc/init.properties "
========================tigase.conf===================================

Very appreciate if you provide support for this case.

Felix Leung
Business Development Manager
felix@syntac.com.hk
(00)852-6852-0855
(00)86-1381-140-3523

15255_SynTac-Logo2B-B-small.jpg (14.9 KB) 15255_SynTac-Logo2B-B-small.jpg felix liang, 2019-02-04 04:23 AM
tigase.log.0 (144 KB) tigase.log.0 felix liang, 2019-02-04 04:23 AM
tigase-console.log (51.5 KB) tigase-console.log felix liang, 2019-02-04 04:23 AM
6716

Associated revisions

Revision 7a88302a (diff)
Added by W Administrator 2 months ago

#8554 force characterEncoding also on actuall the connection string used to access database and no only on the example init.properties configuration

History

#1 Updated by Wojciech Kapcia TigaseTeam 3 months ago

  • Description updated (diff)
  • Status changed from New to In Progress
  • Assignee changed from Wojciech Kapcia to felix liang

Hi,
which MySQL version do you use?

Could you try to execute following queries in your database:

select TigGetDBProperty('schema-version');

select * from tig_pairs, tig_users where (user_id = 'db-properties') AND (tig_pairs.uid = tig_users.uid);

#2 Updated by Wojciech Kapcia TigaseTeam 2 months ago

  • Subject changed from !!!!NOT WORKING !!!Solution of Bug #6753: update schema problem - Tigase XMPP Server - Tigase Projects to [MySQL] Sometimes setting version via property doesn't work (without error)
  • Assignee changed from felix liang to Wojciech Kapcia

I reproduced the issue locally - I'm continuing investigation.

#3 Updated by Wojciech Kapcia TigaseTeam 2 months ago

  • Tracker changed from Support to Bug
  • Project changed from Support to Tigase XMPP Server
  • Status changed from In Progress to Resolved
  • Target version set to tigase-server-7.1.6
  • % Done changed from 0 to 100
  • Applicable version set to 7.1.3
  • Source Code Disclaimer set to No
  • Database n/a added

DBSchemaLoader was setting character encoding in example configuration string but not in the actual jdbc urls.

#4 Updated by Wojciech Kapcia TigaseTeam 2 months ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF