[Solved] Unable to perform db:migrate at v2.6.1, error "index contains unexpected zero page at block 39700"


#1

EDIT: Please close this topic. Fixed by running psql mastodon_production > REINDEX INDEX index_statuses_20180106; after cd live as mastodon user.

Hi admins,

I am getting the following issues when running db:migrate.

PG::IndexCorrupted: ERROR: index “index_statuses_20180106” contains unexpected zero page at block 39700
HINT: Please REINDEX it.

Does anyone know how to fix this?

mastodon@host:~/live$ RAILS_ENV=production bundle exec rails db:migrate
Migrating to MigrateAccountConversations (20181024224956)
== 20181024224956 MigrateAccountConversations: migrating ======================
--
-- WARNING: This migration may take a *long* time for large instances
-- It will *not* lock tables for any significant time, but it may run
-- for a very long time. We will pause for 10 seconds to allow you to
-- interrupt this migration if you are not ready.
--
   -> Continuing in 10 seconds...
   -> Continuing in 9 seconds...
   -> Continuing in 8 seconds...
   -> Continuing in 7 seconds...
   -> Continuing in 6 seconds...
   -> Continuing in 5 seconds...
   -> Continuing in 4 seconds...
   -> Continuing in 3 seconds...
   -> Continuing in 2 seconds...
   -> Continuing in 1 second...
rails aborted!
StandardError: An error has occurred, all later migrations canceled:

PG::IndexCorrupted: ERROR:  index "index_statuses_20180106" contains unexpected zero page at block 39700
HINT:  Please REINDEX it.
: SELECT  "statuses".* FROM "statuses" WHERE ("statuses"."local" = $1 OR "statuses"."uri" IS NULL) AND "statuses"."visibility" = $2 ORDER BY "statuses"."id" ASC LIMIT $3
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:614:in `async_exec_prepared'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:614:in `block (2 levels) in exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:613:in `block in exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:612:in `exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:592:in `execute_and_clear'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:81:in `exec_query'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:469:in `select_prepared'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:55:in `select_all'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/query_cache.rb:101:in `select_all'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:41:in `find_by_sql'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:554:in `block in exec_queries'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:575:in `block in skip_query_cache_if_necessary'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/query_cache.rb:78:in `uncached'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/query_cache.rb:21:in `uncached'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `public_send'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `block in method_missing'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:281:in `scoping'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `method_missing'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:574:in `skip_query_cache_if_necessary'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:541:in `exec_queries'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:414:in `load'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:200:in `records'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:224:in `block in in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:222:in `loop'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:222:in `in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:135:in `find_in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:69:in `find_each'
/home/mastodon/live/db/migrate/20181024224956_migrate_account_conversations.rb:20:in `up'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:817:in `exec_migration'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:798:in `block (2 levels) in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:797:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:414:in `with_connection'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:796:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/strong_migrations-0.3.1/lib/strong_migrations/migration.rb:13:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/strategy.rb:70:in `wrap'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy.rb:201:in `strategy'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:977:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1292:in `block in execute_migration_in_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1345:in `ddl_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1291:in `execute_migration_in_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1263:in `block in migrate_without_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `each'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `migrate_without_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1210:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1363:in `with_advisory_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1210:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/strategy.rb:70:in `wrap'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy.rb:201:in `strategy'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1036:in `up'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1011:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/tasks/database_tasks.rb:172:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/strong_migrations-0.3.1/lib/strong_migrations/database_tasks.rb:4:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/railties/databases.rake:60:in `block (2 levels) in <top (required)>'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands/rake/rake_command.rb:20:in `perform'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/command.rb:48:in `invoke'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands.rb:18:in `<top (required)>'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:287:in `block in require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:253:in `load_dependency'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:287:in `require'
bin/rails:4:in `<main>'

Caused by:
ActiveRecord::StatementInvalid: PG::IndexCorrupted: ERROR:  index "index_statuses_20180106" contains unexpected zero page at block 39700
HINT:  Please REINDEX it.
: SELECT  "statuses".* FROM "statuses" WHERE ("statuses"."local" = $1 OR "statuses"."uri" IS NULL) AND "statuses"."visibility" = $2 ORDER BY "statuses"."id" ASC LIMIT $3
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:614:in `async_exec_prepared'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:614:in `block (2 levels) in exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:613:in `block in exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:612:in `exec_cache'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:592:in `execute_and_clear'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:81:in `exec_query'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:469:in `select_prepared'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:55:in `select_all'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/query_cache.rb:101:in `select_all'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:41:in `find_by_sql'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:554:in `block in exec_queries'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:575:in `block in skip_query_cache_if_necessary'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/query_cache.rb:78:in `uncached'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/query_cache.rb:21:in `uncached'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `public_send'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `block in method_missing'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:281:in `scoping'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `method_missing'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:574:in `skip_query_cache_if_necessary'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:541:in `exec_queries'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:414:in `load'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:200:in `records'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:224:in `block in in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:222:in `loop'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:222:in `in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:135:in `find_in_batches'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/batches.rb:69:in `find_each'
/home/mastodon/live/db/migrate/20181024224956_migrate_account_conversations.rb:20:in `up'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:817:in `exec_migration'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:798:in `block (2 levels) in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:797:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:414:in `with_connection'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:796:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/strong_migrations-0.3.1/lib/strong_migrations/migration.rb:13:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/strategy.rb:70:in `wrap'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy.rb:201:in `strategy'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:977:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1292:in `block in execute_migration_in_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1345:in `ddl_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1291:in `execute_migration_in_transaction'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1263:in `block in migrate_without_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `each'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `migrate_without_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1210:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1363:in `with_advisory_lock'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1210:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `block in migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/strategy.rb:70:in `wrap'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy.rb:201:in `strategy'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/chewy-5.0.0/lib/chewy/railtie.rb:37:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1036:in `up'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1011:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/tasks/database_tasks.rb:172:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/strong_migrations-0.3.1/lib/strong_migrations/database_tasks.rb:4:in `migrate'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.1/lib/active_record/railties/databases.rake:60:in `block (2 levels) in <top (required)>'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands/rake/rake_command.rb:20:in `perform'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/command.rb:48:in `invoke'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/railties-5.2.1/lib/rails/commands.rb:18:in `<top (required)>'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:287:in `block in require'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:253:in `load_dependency'
/home/mastodon/live/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.1/lib/active_support/dependencies.rb:287:in `require'
bin/rails:4:in `<main>'
Tasks: TOP => db:migrate
(See full trace by running task with --trace)

#2

Open the psql console and run REINDEX index_statuses_20180106;


#3

Hi @Gargron,

Yep, did that and it worked. Thank you. :slight_smile: