Consider increasing the configuration parameter "max_wal_size"

AI-generated summary

@diegoeis encountered an error while trying to rebuild their Discourse app after changing the SMTP address in app.yml. The error message suggested increasing the configuration parameter “max_wal_size” due to frequent checkpoints.

@diegoeis claims to have solved the issue by following the commands provided by @codinghorror in a related post.

@codinghorror responded, asking if the issue was caused by running out of disk space, as the wal errors are related to Postgres writing its database change log to disk.

Hi, I’m trying change the smtp address of my smtp email server. I edit my app.yml, change the address, :wq to save, and try rebuild the app. In a specific point, the system warn me this error.

Using spork-rails 4.0.0
0:  spork-rails (4.0.0) from /var/www/discourse/vendor/bundle/ruby/2.3.0/specifications/spork-rails-4.0.0.gemspec
Bundle complete! 99 Gemfile dependencies, 179 gems now installed.
Gems in the group development were not installed.
Bundled gems are installed into ./vendor/bundle.

I, [2016-07-10T04:04:40.895077 #13]  INFO -- : > cd /var/www/discourse && su discourse -c 'bundle exec rake db:migrate'
2016-07-10 04:05:40 UTC [46-1] LOG:  checkpoints are occurring too frequently (24 seconds apart)
2016-07-10 04:05:40 UTC [46-2] HINT:  Consider increasing the configuration parameter "max_wal_size".
2016-07-10 04:06:00 UTC [46-3] LOG:  checkpoints are occurring too frequently (20 seconds apart)
2016-07-10 04:06:00 UTC [46-4] HINT:  Consider increasing the configuration parameter "max_wal_size".
2016-07-10 04:06:19 UTC [46-5] LOG:  checkpoints are occurring too frequently (19 seconds apart)
2016-07-10 04:06:19 UTC [46-6] HINT:  Consider increasing the configuration parameter "max_wal_size".
2016-07-10 04:06:36 UTC [46-7] LOG:  checkpoints are occurring too frequently (17 seconds apart)
2016-07-10 04:06:36 UTC [46-8] HINT:  Consider increasing the configuration parameter "max_wal_size".
2016-07-10 04:06:53 UTC [46-9] LOG:  checkpoints are occurring too frequently (17 seconds apart)
2016-07-10 04:06:53 UTC [46-10] HINT:  Consider increasing the configuration parameter "max_wal_size".

I think I solved this issue making the commands given by @codinghorror in this post:
https://meta.discourse.org/t/discourse-using-almost-95-of-40gb-total-drive-space-is-this-a-problem/43966/2?u=diegoeis

Were you out of disk space? The wal stuff has to do with postgres streaming its real time log of database changes to disk.