Projects tigase _server server-core Issues #1455
Tigase Cluster Installation (#1455)
Unknown opened 3 years ago

We have a problem with the setup of the Tigase 2 nodes Cluster:

We have setup a cluster using 2 nodes Tigase 7.1 and a shared Postgresql DB. The initialization of cluster is OK. No problem. We can see the cluster is communication through port 5277.

The Problem is: We have an app and we need presence information for the app to perform. As there are two nodes, we have two UI in different external IPs and when we enter to one Tigase UI we see our client online but in the other node Tigase UI, our client is not visible online. Although the db is shared external, that info is not passed to the second node.

During our studies we have found out that may be we need ACS but we are not sure. Please see attached our init.properties file.

Your help is appreciated. Thanks in advance.

--user-db-uri = ***********
--user-db = pgsql
--admins = *********************
config-type = --gen-config-def
--comp-name-1 = muc
--comp-name-2 = pubsub
--comp-name-3 = proxy
--comp-name-4 = message-archive
--comp-name-5 = http
--comp-name-6 = rest
--comp-name-7 = sess-man

--comp-class-1 = tigase.muc.cluster.ShardingStrategy
--comp-class-2 = tigase.pubsub.cluster.PubSubNodeClustered
--comp-class-3 = tigase.socks5.Socks5ProxyComponent
--comp-class-4 = tigase.archive.MessageArchiveComponent
--comp-class-5 = tigase.http.HttpMessageReceiver
--comp-class-6 = tigase.http.rest.RestMessageReceiver
--comp-class-7 = tigase.server.cluster.strategy.OnlineUsersCachingStrategy

--cl-conn-repo-class = tigase.cluster.repo.ClConSQLRepository
cl-comp/repo-uri=jdbc:postgresql://10.128.0.55/tigase?user=tigase&password=tigasepassword

--cluster-mode = true
--cl-comp-ports=5277,5278

--client-port-delay-listening=true
bosh/port-delay-listening[B]=true
c2s/port-delay-listening[B]=true
ws2s/port-delay-listening[B]=true

#--cluster-nodes = 10.128.0.53,10.128.0.55
#--cluster-connect-all=true

--sm-plugins = +message-archive-xep-0136

http/http/port[I]=8080
http/server-class[S]=tigase.http.java.JavaStandaloneHttpServer
vhost-man/domains-per-user-limit[I]=100000
http/rest/api-keys[s]=4ec2edea84e6411cb5547c01ade7acf6

--vhost-disable-dns-check = true
--virt-hosts = ********************************
--vhost-tls-required = true
--ssl-def-cert-domain = *************************
basic-conf/virt-hosts-cert-*.****************************

Setup DETAILS:

  • Tigase version: [7.1.4]
  • JVM flavour and version [JDK8]
  • Operating system/distribution/version [Linux Ubuntu 18.04]
Unknown commented 3 years ago

Hi!

We have an app and we need presence information for the app to perform. As there are two nodes, we have two UI in different external IPs and when we enter to one Tigase UI we see our client online but in the other node Tigase UI, our client is not visible online. Although the db is shared external, that info is not passed to the second node.

First of all - database is only used to store information about users, but is not used to exchange dynamic presence information. The presence itself (and message exchange happens) over cluster connection (port 5277) directly.

A couple of pointers:

  1. can you send messages between users connected to different cluster nodes? Or only presence is missing?
  2. are the cluster nodes connected correctly? You can check that using "Get list of all connected cluster nodes" command (either via admin web-ui in the configuration section or via XMPP and ad-hoc commands: service discovery - cluster connection manager)
  3. are there any exceptions in the logs regarding cluster connectivity?

Btw. I would recommend using latest stable version: 8.1.0.

Unknown commented 3 years ago

Thank you:

  1. Our app does not send messages to other nodes, but we only need presence information that is not working right now.
  2. Cluster nodes configured correctly as I get from each of the ui "Get list of all connected cluster nodes" the 2 nodes are seen on each node UI.
  3. No

Our db schema is old and I could not manage to upgrade the system. Is there a solution for that to upgrade the data in tables for 8.1.0.

Unknown commented 3 years ago

Our app does not send messages to other nodes, but we only need presence information that is not working right now.

I assumed as much. I was suggesting a test if messages are being delivered across the cluster.

A couple more of troubleshooting questions:

  1. does the issue manifest it both users connect to the same node?
  2. do you have any PrivacyList/blocking configure for users?
  3. do you see in the logs that messages/presences are being forwarded to the other node (you can enable debuging for package cluster to trace those deliveries)

Our db schema is old and I could not manage to upgrade the system. Is there a solution for that to upgrade the data in tables for 8.1.0.

In general there is an schema upgrade script that should handle the whole process without any problems: https://docs.tigase.net/tigase-server/master-snapshot/Administration_Guide/html/#_upgrade_database_schema

issue 1 of 1
Type
Question
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/server-core#1455
Please wait...
Page is in error, reload to recover