Cannot access admin pages after old backup restore

I’m trying to restore a backup taken from a self-hosted discourse instance that was not updated since May 2021. The app.yml was not customized (no plugin).

I restored the backup on a fresh instance. The messages and users were fortunately restored. However, the sidebar does not give access to most administration options:

Moreover, most administration pages are no longer accessible. For example, I cannot access the backups admin page https://<mydomain.org>/admin/backups/settings as it gives a “Page not found” error.

I still can administer that instance using the command line (./launcher enter app). However that’s not very convenient and I fear the database could be in a somewhat inconsistent state.

Can you think of a means to restore the admin pages? Thanks!

Hey there, I hope you are well.
It sounds like there may be a version difference between your backup and the new Discourse instance, especially since the original instance was last updated in May 2021.

To resolve this, try matching the versions by checking the old version in your app.yml file, switching the new instance to that version, and then rebuilding. If that doesn’t work, reset the settings and clear any cache by running Rails.cache.clear inside the container and then rebuilding the app.

This should help restore access to your admin pages and ensure everything is compatible.

Thank You,
Mike Taku.

1 Like

Maybe your account is a moderator account but not an admin account?

Thanks a lot @Mike_Taku and @Ed_S for your quick and relevant replies!

My user was indeed only moderator, and not administrator! I was able to change the permission of my user using the console and then see all the admin settings.

While my initial misunderstanding of the discourse roles is the cause of my issue, the symbol displayed in the user tab could be different between admin and moderator. It’s only when the cursor is hovering over that symbol that a tooltip displays “Administrator” or “Moderator”.

image

1 Like