Service unavailable ERF64-6496 [Foreman::MaintenanceException]: There are migrations pending in the system

Problem:
After running yum update, foreman does not work anymore, the web interface just displays the above error-message
Expected outcome:
Should work
Foreman and Proxy versions:
foreman-2.4.1-1.el8.noarch
foreman-proxy-2.4.1-1.el8.noarch

Foreman and Proxy plugin versions:

Distribution and version:
CentOS Linux release 8.4.2105
Other relevant data:

I tried

foreman-rake db:migrate 
foreman-rake db:seed 

and it did apparently fix some stuff:

Rubocop not loaded.
API controllers newer than Apipie cache! Run apipie:cache rake task to regenerate cache.
== 20210525144427 EnforceUniqueTemplates: migrating ===========================
-- add_index(:templates, [:type, :name], {:unique=>true})
   -> 0.0315s
== 20210525144427 EnforceUniqueTemplates: migrated (0.0459s) ==================

== 20210610131920 RestrictSendmailLocation: migrating =========================
== 20210610131920 RestrictSendmailLocation: migrated (0.0031s) ================

But it still shows this error-message.

1 Like

Try running the foreman-rake db:migrate again just in case, then also try to restart the foreman service.

4 Likes

Ah, yes.
I actually needed to restart.

Just tried that.
D’oh!

After that foreman works again :slight_smile:

foreman-rake db:migrate worked great for me!

My System:

  • AlmaLinux 8.8
  • Foreman 3.5.3
  • Katello 4.7.6