Focus error

I try to script a Jitsi-installation, and try a manual installation.

I got Coturn and Nginx configured I guess. I configured Prosody to some level but I don’t understand why the Webfrontend can not connect / just retries after 20s. I went into the browser-console to see for JS errors.


Logger.js:154:22
2022-11-01T13:38:28.780Z [modules/xmpp/moderator.js] <6628/_r.prototype._allocateConferenceFocusError>: Focus error, retry after 4000

Logger.js:154:22
2022-11-01T13:38:28.801Z [conference.js] <_onConferenceFailed>: CONFERENCE FAILED: conference.focusDisconnected focus.jitsi.example.net 4 Logger.js:152:43
2022-11-01T13:38:32.808Z [modules/xmpp/moderator.js] <6628/_r.prototype.setFocusUserJid>: Focus jid set to: undefined Logger.js:154:22
2022-11-01T13:38:32.811Z [modules/xmpp/moderator.js] <6628/_r.prototype.createConferenceIq>: Session ID: null machine UID: d29b01d2db340d7ce1e03b4f881f946a Logger.js:154:22
2022-11-01T13:38:32.872Z [JitsiMeetJS.js] : UnhandledError: Focus error, retry after 8000 Script: null Line: null Column: null StackTrace: 6628/_r.prototype._allocateConferenceFocusError@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:414557
6628/_r.prototype.allocateConferenceFocus/</<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413580
6033/sendIQ/a<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:226714
run@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:222013
6033/_dataRecv/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:230451
forEachChild@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:213681
_dataRecv@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:230300
_onRequestStateChange@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:250284
EventHandlerNonNull*_newXHR@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:244107
6033/D.Request@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:242995
_onIdle@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:248758
_onIdle@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:238490
flush@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:225800
flush@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:394634
6628/_r.prototype.allocateConferenceFocus/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413633
6628/_r.prototype.allocateConferenceFocus@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413399
6628/_r.prototype._allocateConferenceFocusError/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:414731
setTimeout handler6628/_r.prototype._allocateConferenceFocusError@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:414710
6628/_r.prototype.allocateConferenceFocus/</<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413580
6033/sendIQ/a<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:226714
run@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:222013
6033/_dataRecv/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:230451
forEachChild@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:213681
_dataRecv@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:230300
_onRequestStateChange@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:250284
EventHandlerNonNull
_newXHR@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:244107
6033/D.Request@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:242995
_onIdle@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:248758
_onIdle@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:238490
6033/_onIdle/this._idleTimeout<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:238567
setTimeout handler*_onIdle@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:238535
flush@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:225800
flush@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:394634
6628/_r.prototype.allocateConferenceFocus/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413633
6628/_r.prototype.allocateConferenceFocus@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:413399
6628/join/<@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:418572
join@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:418411
6628/ku.prototype.join@https://jitsi.example.net/libs/lib-jitsi-meet.min.js?v=6644:2:760625
connect@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:691854
8064/startConference/<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:695307
startConference@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:695273
init@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:696640
async8064/_start/</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:615876
promise callback
8064/_start/<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:615851
8064/_a/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:2:84775
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:903900
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:888576
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:888061
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:883698
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:883070
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:882102
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:878334
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:877364
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:874511
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:874434
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:872623
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:865037
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:864837
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:863837
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:859741
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:858424
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:855439
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:854065
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:852392
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:852062
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:851052
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:850644
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:847540
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:838869
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:838521
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:838237
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:838197
8064/</</<@https://jitsi.example.net/libs/app.bundle.min.js?v=6644:180:832610
Logger.js:154:22
2022-11-01T13:38:32.874Z [modules/xmpp/moderator.js] <6628/_r.prototype._allocateConferenceFocusError>: Focus error, retry after 8000

Logger.js:154:22
2022-11-01T13:38:32.923Z [conference.js] <_onConferenceFailed>: CONFERENCE FAILED: conference.focusDisconnected focus.jitsi.example.net 8 Logger.js:152:43

I can login into the prosody server with a standard xmpp client. What is the first step to check for such focus error message?

Thanks in advance

Check your jicofo logs for errors.

I’ve found this…

Jicofo 2022-11-01 17:42:05.956 WARNING: [379856] org.jivesoftware.smack.AbstractXMPPConnection.callConnectionClosedOnErrorListener: Connection XMPPTCPConnection[not-authenticated] (0) closed with error
javax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:353)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:296)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:291)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(CertificateMessage.java:1357)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(CertificateMessage.java:1232)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(CertificateMessage.java:1175)
at java.base/sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:392)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:443)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:421)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:183)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:172)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1506)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1416)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:456)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:427)
at org.jivesoftware.smack.tcp.XMPPTCPConnection.proceedTLSReceived(XMPPTCPConnection.java:733)
at org.jivesoftware.smack.tcp.XMPPTCPConnection.access$1400(XMPPTCPConnection.java:131)
at org.jivesoftware.smack.tcp.XMPPTCPConnection$PacketReader.parsePackets(XMPPTCPConnection.java:990)
at org.jivesoftware.smack.tcp.XMPPTCPConnection$PacketReader.access$700(XMPPTCPConnection.java:916)
at org.jivesoftware.smack.tcp.XMPPTCPConnection$PacketReader$1.run(XMPPTCPConnection.java:939)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:439)
at java.base/sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:306)
at java.base/sun.security.validator.Validator.validate(Validator.java:264)
at java.base/sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:313)
at java.base/sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:222)
at java.base/sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:129)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(CertificateMessage.java:1341)
… 17 more
Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:141)
at java.base/sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:126)
at java.base/java.security.cert.CertPathBuilder.build(CertPathBuilder.java:297)
at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:434)
… 23 more

but how to interpret this? Is prosody malconfigured?

lrwxrwxrwx 1 root root 50 Oct 21 19:08 jitsi.example.net.cfg.lua → /etc/prosody/conf.avail/jitsi.example.net.cfg.lua
lrwxrwxrwx 1 root root 41 Oct 26 12:09 localhost.cfg.lua → /etc/prosody/conf.avail/localhost.cfg.lua

/etc/prosody/conf.d/jitsi.example.net.cfg.lua


VirtualHost “auth.jitsi.example.net
ssl = {
key = “/var/lib/prosody/auth.jitsi.example.net.key”;
certificate = “/var/lib/prosody/auth.jitsi.example.net.crt”;
}
authentication = “internal_hashed”

/etc/prosody/conf.d/localhost.cfg.lua

VirtualHost “localhost”
authentication = “jitsi-anonymous” – do not delete me
– Properties below are modified by jitsi-meet-tokens package config
– and authentication above is switched to “token”
–app_id=“example_app_id”
–app_secret=“example_app_secret”
– Assign this host a certificate for TLS, otherwise it would use the one
– set in the global section (if any).
– Note that old-style SSL on port 5223 only supports one certificate, and will always
– use the global one.
ssl = {
key = “/etc/prosody/certs/localhost.key”;
certificate = “/etc/prosody/certs/localhost.crt”;
}

So I took at the certificates…

ls /var/lib/prosody -al
drwxr-x— 9 prosody prosody 4096 Oct 26 12:35 .
drwxr-xr-x 39 root root 4096 Oct 21 19:50 …
drwxr-x— 8 prosody prosody 4096 Nov 1 01:35 auth%2ejitsi%2eexample%2enet
drwxr-x— 5 prosody prosody 4096 Nov 1 01:35 auth%2elocalhost
-rw-r----- 1 prosody prosody 889 Oct 21 19:14 auth.jitsi.example.net.cnf
-rw-r----- 1 prosody prosody 1720 Oct 21 19:14 auth.jitsi.example.net.crt
-r-------- 1 prosody prosody 1704 Oct 21 19:14 auth.jitsi.example.net.key
-rw-r----- 1 prosody prosody 1019 Oct 26 12:09 auth.localhost.cnf
-rw-r----- 1 prosody prosody 1785 Oct 26 12:09 auth.localhost.crt
-r-------- 1 prosody prosody 1708 Oct 26 12:09 auth.localhost.key
drwxr-x— 4 prosody prosody 4096 Aug 30 13:21 custom_plugins
-rw-r----- 1 prosody prosody 1048 Oct 21 19:13 jitsi.example.net.cnf
-rw-r----- 1 prosody prosody 1838 Oct 21 19:13 jitsi.example.net.crt
-r-------- 1 prosody prosody 1704 Oct 21 19:13 jitsi.example.net.key
drwxr-x— 2 prosody prosody 4096 Nov 1 11:35 localhost
-rw-r----- 1 prosody prosody 2812 Oct 26 12:09 localhost.cnf
-rw-r----- 1 prosody prosody 3219 Oct 26 12:09 localhost.crt
-r-------- 1 prosody prosody 1704 Oct 26 12:09 localhost.key
srwxr-x— 1 prosody prosody 0 Oct 26 12:35 prosody.sock

ls /etc/prosody/certs/
auth.localhost.crt auth.localhost.key GNUmakefile localhost.cnf localhost.crt localhost.key makefile openssl.cnf

Is my error somewhere in these outputs or should I look at some other place?

What steps did you follow to install the packages?

You can add this to your jicofo.conf

With the value of true, to workaround this issue.

Following the Self-Hosting Guide - Debian/Ubuntu server | Jitsi Meet and you should not hit this problem.