Why is Craft returning a 504 during a system update? There have been a few updates to the system and some of the plugins I am using. I have installed everything locally and a plugin needed to run new migrations as a result of the update.

Everything works great locally, I went to /admin to "Finish up" the updates.

Now I have moved the files out to my staging server. I always manually update (even though Craft will do this for me). Once all of the files have deployed, I once again visit /admin to run the migrations.

However, the database is quite large (> 100MB) and I am getting a 504 Gateway timeout error.

What can I do to fix this?
I've had this issue before.

It's usually to do with one of two things for me - either the PHP script timeout value or the FPM proxy timeout value.

Another method of fixing this is to change the update settings in the general Craft configuration:

'backupDbOnUpdate' =&gt; false,


Keep in mind though that you will need to back up the database yourself.