Strophe 504 Errors Occur when setting storage = "sql"

Hello,

I have jitsi installed on Ubuntu 18.10 with Prosody version 0.11.6. The setup was running fine until I had changed storage to sql.

Here is a Break-Down of what I have done after installing Jitsi:

-I have upgraded prosody version from v0.10 to v0.11.6 following this link: [How to] How do I update Prosody?
-setup SECURE DOMAIN following this link: https://jitsi.github.io/handbook/docs/devops-guide/secure-domain.

The setup runs great. Lobby works fine as well. Able to have conferences with multiple participants with no issues.

Then:

-set storage = “sql” in my prosody.cfg.lua file and have declared values to connect to an EXTERNAL mysql database server
-changed storage = “sql” in my domain.com.cfg.lua wherever storage is being declared

When I Reboot my machine, I see:

-two tables were automatically created in my database
-when registering users, they are being stored in one of these tables (prosody)
-able to start a conference successfully with host authentication.
-the conference is running fine, even when I have participants join (tested with upto 6 participants).
-lobby and room password is working

Whats the problem?

-After removing all participants except for one (conference is still running), people cannot join the same conference
-with lobby active, the one remaining participant sees the notification when a person is trying to join, BUT pressing “allow” does not let the waiting participant in.
-Room password does not work either.
-when conference is ended, and a new conference is started, the screen is grey and an error message which shows “unable to access camera” is popping up.
-No errors reported in prosody logs

Errors in the console:

Failed to load resource: the server responded with a status of 504 ()
Logger.js:154 2020-09-30T12:17:59.565Z [JitsiMeetJS.js] <Object.getGlobalOnErrorHandler>: UnhandledError: null Script: null Line: null Column: null StackTrace: Error: Strophe: request id 136.1 error 504 happened
at Object.r.Strophe.log (strophe.util.js:89)
at Object.error (strophe.umd.js:1392)
at D.Bosh._onRequestStateChange (strophe.umd.js:5017)
o @ Logger.js:154
getGlobalOnErrorHandler @ JitsiMeetJS.js:614
window.onerror @ middleware.js:100
callErrorHandler @ GlobalOnErrorHandler.js:63
r.Strophe.log @ strophe.util.js:89
error @ strophe.umd.js:1392
_onRequestStateChange @ strophe.umd.js:5017
Logger.js:154 2020-09-30T12:17:59.568Z [modules/xmpp/strophe.util.js] <Object.r.Strophe.log>: Strophe: request id 136.1 error 504 happened
o @ Logger.js:154
r.Strophe.log @ strophe.util.js:90
error @ strophe.umd.js:1392
_onRequestStateChange @ strophe.umd.js:5017
Logger.js:154 2020-09-30T12:17:59.570Z [modules/xmpp/strophe.util.js] <Object.r.Strophe.log>: Strophe: request errored, status: 504, number of errors: 1
o @ Logger.js:154
r.Strophe.log @ strophe.util.js:77
warn @ strophe.umd.js:1382
_hitError @ strophe.umd.js:4810
_onRequestStateChange @ strophe.umd.js:5019
http-bind:1 Failed to load resource: the server responded with a status of 504 ()
Logger.js:154 2020-09-30T12:18:05.905Z [JitsiMeetJS.js] <Object.getGlobalOnErrorHandler>: UnhandledError: null Script: null Line: null Column: null StackTrace: Error: Strophe: request id 137.1 error 504 happened
at Object.r.Strophe.log (strophe.util.js:89)
at Object.error (strophe.umd.js:1392)
at D.Bosh._onRequestStateChange (strophe.umd.js:5017)
o @ Logger.js:154
getGlobalOnErrorHandler @ JitsiMeetJS.js:614
window.onerror @ middleware.js:100
callErrorHandler @ GlobalOnErrorHandler.js:63
r.Strophe.log @ strophe.util.js:89
error @ strophe.umd.js:1392
_onRequestStateChange @ strophe.umd.js:5017
Logger.js:154 2020-09-30T12:18:05.906Z [modules/xmpp/strophe.util.js] <Object.r.Strophe.log>: Strophe: request id 137.1 error 504 happened

Can someone please help? All help is greatly appreciated.

Thanks.

Mudassar

Check prosody logs for errors.

Only one error reported in prosody logs. error Error binding encrypted port for https: No certificate present in SSL/TLS configuration for https port 5281
Which I believe can be ignored.

That is strange, 504 means prosody did not respond to the HTTP request … if you remove SQL and everything works? If that is the case enable debug logging in prosody and try again with SQL maybe you will see something …

Yes it works perfectly fine when I remove SQL. I changed it back to “internal” and did not have any issues.

I changed storage back to sql and have enabled debug logging and checked the logs, I still don’t see any errors. There are debug messages which show “SQL transaction begin” and “SQL transaction success” but when starting a conference there is no SQL transaction success statement.

Hey,

Just an FYI, I was able to figure this out. The external SQL Database was behind an NAT network which I believe was causing connectivity issues with XMPP, please do correct me if I am wrong. Thanks for the help and response.

Mudassar