Restore: uncompressed file to big

סיכום מבוסס בינה מלאכותית

The user helmi encountered an error during a forum restore due to the uncompressed file being too large, with a log message referencing the decompressed_theme_max_file_size_mb setting. helmi correctly identified that the issue relates to the decompressed_backup_max_file_size_mb setting, not the theme setting, as confirmed by gerhard. helmi sought guidance on how to adjust the setting and later shared the solution: accessing the console via ./launcher enter app, entering Rails console with rails c, and setting the value using SiteSettings.decompressed_backup_max_file_size_mb=999 (or a higher value like 1000000 for a 1TB limit). helmi clarified that the value should match the expected decompressed backup size.

Hey there,

I’m probing a restore on a migrated forum. The restore package is around 25g and when trying the restore it fails with this message in the log:

[2019-11-24 08:33:00] The uncompressed file is too big. Consider increasing the decompressed_theme_max_file_size_mb hidden setting.

I only found some code references on github with this setting and found some traces of hidden settings needing to be set via console but didn’t find a way how to do so. Also what are resonable values for this setting means what should I try to increase it to?

Any hints are appreciated.

I also found that one which should be in 2.4.0 beta 7 if I got it right (and which is the version I’m on)

https://github.com/discourse/discourse/commit/01bc465db819d5ba0e433a8226c80a9bd38b593d

So it’s probably the backup value I need to rise, not the one for the theme, right?

Yeah, the error message is wrong. I’ll change it. You found the correct setting.

ok, but how do I set a better value? :wink: I just didn’t yet use the console to change settings and somehow couldn’t find out how to do so until now.

Looks like I got it done. In case someone finds the thread, this is how i got it working:

# ./launcher enter app
# rails c
# SiteSettings.decompressed_backup_max_file_size_mb=999

Instead of 999 you should use a value that fits your backup size (decompressed). I set it to 1TB (1000000) as I wasn’t sure how big my 22GB (compressed) backup is when it’s not compressed anymore.