Gateway timeout issue

Hello, i am getting this 504 gateway when using the list filter to remove no open leads. Everything else in mailwizz works fine its just this timeout issue when running the filter which i believe is server related.

I did optimise my server according to this post: https://kb.mailwizz.com/articles/mysql-mariadb-optimisations/ however its not making any difference. Can you recommend any other tweaks i can adjust in my server to avoid this timeout issue?

1631088776046.png

Here is the filter i run just for reference:

1631089087262.png
 

Attachments

  • 1631088671737.png
    1631088671737.png
    20.9 KB · Views: 8
You will have to increase the timeout on PHP's side and on the web server side. By default it's sent to about 30 seconds, you can go to 60 and see if that helps.
 
Hi @twisted1919 im still getting this issue on one particular mailwizz. Its strange because i have 9 other mailwizz on the same server all operating the same way and similar activity.

I had my dev do the database tweeks, we increased the timeout a lot on multiple tests and it did not help.

We did discover whenever we enter a value "in the last X days" field then the timeout issue occurs.

However it only occurs when i select the "Did not open" now if i select "did not click" it works flawlessly.

So as it seems its something to do with "Did not open" function

Do you have any idea how i can fix this issue?
 
Last edited:
Hello,
Simply, if the query is taking a long time the timeout will occur. You noticed very well that the Open selection is triggering this behaviour, but is expected since those queries are really heavy. I suppose that you are having a big number of campaigns which also have many opens and this in combination with the subscribers in the list it will put a lot of stress on your db.

Cosmin
 
Hello,
Simply, if the query is taking a long time the timeout will occur. You noticed very well that the Open selection is triggering this behaviour, but is expected since those queries are really heavy. I suppose that you are having a big number of campaigns which also have many opens and this in combination with the subscribers in the list it will put a lot of stress on your db.

Cosmin
Thanks for the reply Cosmin. Do you have any suggestion how to fix it?
 
If anybody is facing this issue i managed to find a solution. Now i'm getting loading times of less than 10 seconds for large queries.

To achieve this you can simple switch from Mysql to MariaDb and use this optimisation that mailwizz recommends: https://www.mailwizz.com/kb/mysql-mariadb-optimisations/

In some cases it might be complicated to switch from Mysql to MariaDb, so you might need to build a new server from scratch that will allow you to install MariaDb without any issues, then you can transfer the old server files to the new one.

As you can see below image we achieved 5.7 seconds to load the query, compared to before was several minutes and in some cases it would timeout because the server could not handle such a big query.

1648851259354.png
 
Back
Top