Message archiving is not happening (#7)
Khaleel Shaik opened 1 decade ago

Hi,

I have installed the Tigase 5.2 final version source code.

I got the source code from tigase-archiving from git clone https://repository.tigase.org/git/message-archiving.git and copied the source code of tigase.archive.* java packages.

I have enabled the properties

--comp-name-3 = message-archive

--comp-class-3 = tigase.archive.MessageArchiveComponent

message-archive/archive-repo-uri = jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123

sess-man/plugins-conf/message-archive-xep-0136/component-jid=message-archive@lpt-khalshai.bodhtree-int.com

sess-man/plugins-conf/message-archive-xep-0136/required-store-method=message

But the messages are never getting saved into the TIG_MA_MSGS table, what is the mistake I might be doing? Could you please provide me the debug steps so that I can work further.

We are using the Universal client Pidgin tool for testing. From the client side we are enabling the message archiving feature also.

Thanks

Khaleel

Khaleel Shaik commented 1 decade ago

Some more property in my init.propertis files are

--message-archive/auto = true

--user-db = mysql

--user-db-uri = jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123

--admins = admin@localhost

Andrzej Wójcik (Tigase) commented 1 decade ago

Is message-archive-xep-0136 plugin added to list of enabled SM plugins?

From parts of you init.properties file I see that it is not enabled and this might be a reason why message archiving is not working.

At component wiki page I mentioned that following line is required in init.properties file:

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

or if you have other options set there you should add message-archive-xep-0136 to list of coma separted values.

Moreover try to comment out following line:

sess-man/plugins-conf/message-archive-xep-0136/component-jid=message-archive@lpt-khalshai.bodhtree-int.com

as it may create issues and in most cases it may be omited.

Do you have any errors exceptions or warnings in log files?

You may also add following line to increase debug level:

--debug=server,archive
Khaleel Shaik commented 1 decade ago

Thanks for your quick reply.

I have commented out those lines as shown below with # char

#sess-man/plugins-conf/message-archive-xep-0136/component-jid=message-archive@lpt-khalshai.bodhtree-int.com

#sess-man/plugins-conf/message-archive-xep-0136/required-store-method=message

#--message-archive/auto = true

And the plugin also included as

--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

Still not working..

Here is the log log....

componentInfo{Title=Tigase XMPP Server, Version=5.2.0-b3447/48635d0a (2014-02-12/17:29:15), Class=tigase.xml.XMLUtils}

componentInfo{Title=Tigase XMPP Server, Version=5.2.0-b3447/48635d0a (2014-02-12/17:29:15), Class=tigase.util.ClassUtil}

componentInfo{Class=tigase.server.XMPPServer}

2014-04-26 20:54:31.832 [main] DNSResolver.() WARNING: Resolving default host name took: 16

2014-04-26 20:54:31.853 [main] ConfiguratorAbstract.parseArgs() CONFIG: Setting defaults: -Djdbc.drivers=com.mysql.jdbc.Driver = tigase.server.XMPPServer

2014-04-26 20:54:31.854 [main] ConfiguratorAbstract.parseArgs() CONFIG: Setting defaults: --property-file = etc/init.properties

2014-04-26 20:54:31.854 [main] ConfiguratorAbstract.parseArgs() CONFIG: Loading initial properties from property file: etc/init.properties

2014-04-26 20:54:31.855 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-class-1=tigase.muc.cluster.MUCComponentClustered)

2014-04-26 20:54:31.856 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--bosh/connections/5281/socket=ssl)

2014-04-26 20:54:31.856 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--virt-hosts=lpt-khalshai, lpt-khalshai.bodhtree-int.com, localhost)

2014-04-26 20:54:31.856 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--auth-db-uri=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123)

2014-04-26 20:54:31.857 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--user-db-uri=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123)

2014-04-26 20:54:31.857 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--user-db=mysql)

2014-04-26 20:54:31.857 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--bosh-ports=5280,5281)

2014-04-26 20:54:31.858 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--admins=admin@localhost)

2014-04-26 20:54:31.858 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--tls-jdk-nss-bug-workaround-active=true)

2014-04-26 20:54:31.858 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (-comp-class-2=tigase.pubsub.PubSubComponent)

2014-04-26 20:54:31.858 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--bosh-extra-headers-file=/etc/tigase/bosh-extra-headers-file.txt)

2014-04-26 20:54:31.859 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-7=test)

2014-04-26 20:54:31.859 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-6=proxy)

2014-04-26 20:54:31.859 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-5=rest)

2014-04-26 20:54:31.860 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--auth-db=mysql)

2014-04-26 20:54:31.860 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (config-type=--gen-config-all)

2014-04-26 20:54:31.860 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-3=message-archive)

2014-04-26 20:54:31.860 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-2=pubsub)

2014-04-26 20:54:31.861 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-name-1=muc)

2014-04-26 20:54:31.861 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--cluster-mode=false)

2014-04-26 20:54:31.861 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--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)

2014-04-26 20:54:31.862 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--basic-conf/auth-repo-params/sasl-mechs=PLAIN)

2014-04-26 20:54:31.862 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-class-7=test.BoshTest)

2014-04-26 20:54:31.862 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-class-6=tigase.socks5.Socks5ProxyComponent)

2014-04-26 20:54:31.862 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--debug=server,xmpp.impl,db,cluster,tigase.server.bosh,archive)

2014-04-26 20:54:31.863 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-class-5=tigase.http.rest.RestMessageReceiver)

2014-04-26 20:54:31.863 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--bosh/connections/5281/type=accept)

2014-04-26 20:54:31.863 [main] ConfiguratorAbstract.parseArgs() CONFIG: Added default config parameter: (--comp-class-3=tigase.archive.MessageArchiveComponent)

2014-04-26 20:54:31.880 [main] MessageRouter.addRegistrator() INFO: Adding registrator: Configurator

2014-04-26 20:54:31.880 [main] MessageRouter.addComponent() INFO: Adding component:

2014-04-26 20:54:31.881 [main] ConfiguratorAbstract.componentAdded() CONFIG: component: basic-conf

2014-04-26 20:54:31.881 [main] ConfiguratorAbstract.setup() CONFIG: Setting up component: basic-conf

2014-04-26 20:54:31.884 [main] ConfiguratorAbstract.setup() CONFIG: Component basic-conf defaults: {component-id=basic-conf@lpt-khalshai.bodhtree-int.com, def-hostname=lpt-khalshai.bodhtree-int.com, admins=[Ljava.lang.String;@12f9924, scripts-dir=scripts/admin, command/ALL=ADMIN, logging/.level=CONFIG, logging/handlers=java.util.logging.ConsoleHandler java.util.logging.FileHandler, logging/java.util.logging.ConsoleHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.ConsoleHandler.level=WARNING, logging/java.util.logging.FileHandler.append=true, logging/java.util.logging.FileHandler.count=5, logging/java.util.logging.FileHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.FileHandler.limit=10000000, logging/java.util.logging.FileHandler.pattern=logs/tigase.log, logging/tigase.useParentHandlers=true, logging/java.util.logging.FileHandler.level=ALL, logging/tigase.server.level=ALL, logging/tigase.xmpp.impl.level=ALL, logging/tigase.db.level=ALL, logging/tigase.cluster.level=ALL, logging/tigase.tigase.server.bosh.level=ALL, logging/tigase.archive.level=ALL, user-domain-repo-pool=tigase.db.UserRepositoryMDImpl, auth-domain-repo-pool=tigase.db.AuthRepositoryMDImpl, user-repo-pool-size=10, data-repo-pool-size=10, user-repo-class=mysql, user-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, auth-repo-class=mysql, auth-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, ssl-container-class=tigase.io.SSLContextContainer, ssl-certs-location=certs/, ssl-def-cert-domain=default, config-dump-file=etc/config-dump.properties}

2014-04-26 20:54:31.885 [main] ConfiguratorAbstract.setup() CONFIG: Component basic-conf configuration: {component-id=basic-conf@lpt-khalshai.bodhtree-int.com, def-hostname=lpt-khalshai.bodhtree-int.com, admins=[Ljava.lang.String;@12f9924, scripts-dir=scripts/admin, command/ALL=ADMIN, logging/.level=CONFIG, logging/handlers=java.util.logging.ConsoleHandler java.util.logging.FileHandler, logging/java.util.logging.ConsoleHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.ConsoleHandler.level=WARNING, logging/java.util.logging.FileHandler.append=true, logging/java.util.logging.FileHandler.count=5, logging/java.util.logging.FileHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.FileHandler.limit=10000000, logging/java.util.logging.FileHandler.pattern=logs/tigase.log, logging/tigase.useParentHandlers=true, logging/java.util.logging.FileHandler.level=ALL, logging/tigase.server.level=ALL, logging/tigase.xmpp.impl.level=ALL, logging/tigase.db.level=ALL, logging/tigase.cluster.level=ALL, logging/tigase.tigase.server.bosh.level=ALL, logging/tigase.archive.level=ALL, user-domain-repo-pool=tigase.db.UserRepositoryMDImpl, auth-domain-repo-pool=tigase.db.AuthRepositoryMDImpl, user-repo-pool-size=10, data-repo-pool-size=10, user-repo-class=mysql, user-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, auth-repo-class=mysql, auth-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, ssl-container-class=tigase.io.SSLContextContainer, ssl-certs-location=certs/, ssl-def-cert-domain=default, config-dump-file=etc/config-dump.properties}

2014-04-26 20:54:31.886 [main] ConfiguratorAbstract.setProperties() INFO: Propeties size is 38, and here are all propeties: {component-id=basic-conf@lpt-khalshai.bodhtree-int.com, def-hostname=lpt-khalshai.bodhtree-int.com, admins=[Ljava.lang.String;@12f9924, scripts-dir=scripts/admin, command/ALL=ADMIN, logging/.level=CONFIG, logging/handlers=java.util.logging.ConsoleHandler java.util.logging.FileHandler, logging/java.util.logging.ConsoleHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.ConsoleHandler.level=WARNING, logging/java.util.logging.FileHandler.append=true, logging/java.util.logging.FileHandler.count=5, logging/java.util.logging.FileHandler.formatter=tigase.util.LogFormatter, logging/java.util.logging.FileHandler.limit=10000000, logging/java.util.logging.FileHandler.pattern=logs/tigase.log, logging/tigase.useParentHandlers=true, logging/java.util.logging.FileHandler.level=ALL, logging/tigase.server.level=ALL, logging/tigase.xmpp.impl.level=ALL, logging/tigase.db.level=ALL, logging/tigase.cluster.level=ALL, logging/tigase.tigase.server.bosh.level=ALL, logging/tigase.archive.level=ALL, user-domain-repo-pool=tigase.db.UserRepositoryMDImpl, auth-domain-repo-pool=tigase.db.AuthRepositoryMDImpl, user-repo-pool-size=10, data-repo-pool-size=10, user-repo-class=mysql, user-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, auth-repo-class=mysql, auth-repo-url=jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123, ssl-container-class=tigase.io.SSLContextContainer, ssl-certs-location=certs/, ssl-def-cert-domain=default, config-dump-file=etc/config-dump.properties, shared-user-repo=null, shared-user-repo-params=null, shared-auth-repo=null, shared-auth-repo-params=null}

Jid vhost-manager;

2014-04-26 20:54:33.626 [main] VHostManager.setProperties() WARNING: {localhost=Domain: localhost, enabled: true, anonym: true, register: true, maxusers: 0, tls: false, s2sSecret: 045fd3a2-0bd5-4e68-bb87-01725dfc442d, domainFilter: ALL, lpt-khalshai=Domain: lpt-khalshai, enabled: true, anonym: true, register: true, maxusers: 0, tls: false, s2sSecret: cbb937bb-e3c9-40bb-9830-f1797e9e8235, domainFilter: ALL, lpt-khalshai.bodhtree-int.com=Domain: lpt-khalshai.bodhtree-int.com, enabled: true, anonym: true, register: true, maxusers: 0, tls: false, s2sSecret: 06e940ed-af5d-4721-8052-a7749c2b73ee, domainFilter: ALL}

Loading component: bosh :: componentInfo{Class=tigase.server.bosh.BoshConnectionManager}

Loading component: c2s :: componentInfo{Class=tigase.server.xmppclient.ClientConnectionManager}

Loading component: message-archive :: componentInfo{Class=tigase.archive.MessageArchiveComponent}

Loading component: monitor :: componentInfo{Class=tigase.server.monitor.MonitorComponent}

Loading component: muc :: componentInfo{Title=Tigase Advanced Clustering Strategy - MUC Component, Version=1.0.0-b15/e8435c02, Class=tigase.muc.cluster.MUCComponentClustered, componentData={MUCClusteringStrategy=class tigase.muc.cluster.DefaultStrategy}}

Loading component: proxy :: componentInfo{Title=Tigase Socks5 Component, Version=1.0.0-b41/0e920198, Class=tigase.socks5.Socks5ProxyComponent}

Loading component: pubsub :: componentInfo{Class=tigase.server.xmppcomponent.ComponentConnectionManager}

2014-04-26 20:54:34.512 [main] ConfigRepository.setProperties() WARNING: Items list is not set in the configuration file!!

Jid rest;

2014-04-26 20:54:34.603 [main] HttpServer.setProperties() WARNING: no HttpRegistrator instance where useLocal = true

2014-04-26 20:54:34.940:INFO:oejs.Server:jetty-8.1.9.v20130131

2014-04-26 20:54:34.975:INFO:oejs.AbstractConnector:Started SelectChannelConnector@0.0.0.0:8080

Loading component: rest :: componentInfo{Title=Tigase HTTP API component: Tigase HTTP API component, Version=1.0.0-b24/19ddb697, Class=tigase.http.rest.RestMessageReceiver}

Loading component: s2s :: componentInfo{Class=tigase.server.xmppserver.S2SConnectionManager}

Loading plugin: session-close=4 ...

Loading plugin: session-open=4 ...

Loading plugin: default-handler=4 ...

Loading plugin: jabber:iq:register=4 ...

Loading plugin: jabber:iq:auth=4 ...

Loading plugin: urn:ietf:params:xml:ns:xmpp-sasl=4 ...

Loading plugin: urn:ietf:params:xml:ns:xmpp-bind=4 ...

Loading plugin: urn:ietf:params:xml:ns:xmpp-session=4 ...

Loading plugin: jabber:iq:roster=8 ...

Loading plugin: jabber:iq:privacy=4 ...

Loading plugin: jabber:iq:version=4 ...

Loading plugin: http://jabber.org/protocol/stats=4 ...

Loading plugin: starttls=4 ...

Loading plugin: vcard-temp=4 ...

Loading plugin: http://jabber.org/protocol/commands=4 ...

Loading plugin: jabber:iq:private=4 ...

Loading plugin: urn:xmpp:ping=4 ...

Loading plugin: presence=8 ...

Loading plugin: disco=4 ...

Loading plugin: amp=4 ...

Loading plugin: message-carbons=4 ...

Loading plugin: message-archive-xep-0136=4 ...

MA LOADED = message-archive@lpt-khalshai.bodhtree-int.com

Loading plugin: msgoffline=4 ...

Loading component: sess-man :: componentInfo{Class=tigase.server.xmppsession.SessionManager}

Jid srecv@lpt-khalshai.bodhtree-int.com;

Loading component: srecv :: componentInfo{Class=tigase.server.sreceiver.StanzaReceiver}

Loading component: ssend :: componentInfo{Class=tigase.server.ssender.StanzaSender}

TESTBOSH component is loaded....successfully

Loading component: test :: componentInfo{Class=test.BoshTest}

Loading component: ws2s :: componentInfo{Class=tigase.server.websocket.WebSocketClientConnectionManager}

2014-04-26 20:54:37.524 [main] ConfigurationCache.store() WARNING: Dumping server configuration to: etc/config-dump.properties

2014-04-26 20:54:59.534 [ConnectionOpenThread] SocketThread.() WARNING: 17 socketReadThreads started.

2014-04-26 20:54:59.554 [ConnectionOpenThread] SocketThread.() WARNING: 17 socketWriteThreads started.

Khaleel Shaik commented 1 decade ago

Here is the my complete init.properties file

--virt-hosts = lpt-khalshai, lpt-khalshai.bodhtree-int.com, localhost

--auth-db = mysql

--auth-db-uri = jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123

--user-db = mysql

--user-db-uri = jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123

--admins = admin@localhost

#config-type = --gen-config-def

config-type = --gen-config-all

--comp-name-1 = muc

#--comp-class-1 = tigase.muc.MUCComponent

--comp-class-1 = tigase.muc.cluster.MUCComponentClustered

--comp-name-2 = pubsub

-comp-class-2 = tigase.pubsub.PubSubComponent

#--comp-class-2 = tigase.pubsub.cluster.PubSubComponentClustered

--comp-name-3 = message-archive

--comp-class-3 = tigase.archive.MessageArchiveComponent

message-archive/archive-repo-uri = jdbc:mysql://localhost/tigasenewdb?user=tigase&password=tigase123

#sess-man/plugins-conf/message-archive-xep-0136/component-jid=message-archive@lpt-khalshai.bodhtree-int.com

#sess-man/plugins-conf/message-archive-xep-0136/required-store-method=message

--message-archive/auto = true

#--comp-name-4 = stun

#--comp-class-4 = tigase.stun.StunComponent

--comp-name-5 = rest

--comp-class-5 = tigase.http.rest.RestMessageReceiver

--comp-name-6 = proxy

--comp-class-6 = tigase.socks5.Socks5ProxyComponent

--comp-name-7 = test

--comp-class-7 = test.BoshTest

--cluster-mode = false

#--cluster-nodes= (add comma separated if there are more servers in cluster)

--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

--debug = server,xmpp.impl,db,cluster,tigase.server.bosh,archive

#Khaleel added

--tls-jdk-nss-bug-workaround-active=true

--bosh-extra-headers-file=/etc/tigase/bosh-extra-headers-file.txt

--bosh-ports=5280,5281

--bosh/connections/5281/socket=ssl

--bosh/connections/5281/type=accept

#For Embeded Jetty Server for HTTP-API server

#--port=8080

#--context=/rest

#--rest-scripts-dir=/scripts/rest/

#--rest/use-local-server=false

--basic-conf/auth-repo-params/sasl-mechs=PLAIN

Khaleel Shaik commented 1 decade ago

--debug=server,archive is included in the init.properties file, still nothing logging in the server console.

Andrzej Wójcik (Tigase) commented 1 decade ago

I would suggest to try following settings:

#sess-man/plugins-conf/message-archive-xep-0136/component-jid=message-archive@lpt-khalshai.bodhtree-int.com
sess-man/plugins-conf/message-archive-xep-0136/required-store-method=message
#--message-archive/auto = true

as

--message-archive/auto - does nothing

and by default component logs only messages for users that enabled logging manually, to force it to log messages for everyone you need following line:

sess-man/plugins-conf/message-archive-xep-0136/required-store-method=message
Khaleel Shaik commented 1 decade ago

Great help !!! Its saving two messages one for sender point of view and another from receiver point of view, great.

I would like to thanks you a bunch.

issue 1 of 1
Type
Consulting
Priority
Normal
Assignee
RedmineID
1944
Issue Votes (0)
Watchers (0)
Reference
tigase/_server/tigase-message-archiving#7
Please wait...
Page is in error, reload to recover