Lost admin user after import from slack

I was able to successfully import slack channels. I had to map my (admin) user to match mattermost but eventually it all worked. However, after doing so, I’ve lost all elevated permissions. System console option wasn’t even there in the menu. I psql into user table and added “system_admin” to my role and that put it back in the menu but when I navigate to system console it gives me white screen and

You do not have the appropriate permissions


What does one need to adjust to get superuser back?

Edit: having both these permissions doesn’t help system_admin,system_manager and neither does changing schemeadmin in teammembers table.

Edit 2: I observed from a fresh installation that spaces are needed as the delimiter system_admin system_user. I also confirmed the teammembers table change. Unfortunately, I am still getting an error so I may have to go nuclear

I recently migrated from Slack to Mattermost and found a solution to that issue. The trick is you need to create an additional account in the clean Mattermost installation before you perform the import of your Slack data. Below is the full explanation of how I successfully migrated.

  1. Determine the official name of your Slack instance (mine was something strange that didnt match the display name – e.g. my Slack name was something like this “slackinstancenam-k948573”)

  2. Export everything from your Slack instance. You can use this guide →

  3. Stand up your new Mattermost instance. I did mine in Docker on my NAS.

  4. Setup your new instance with the same email and username your admin account has in Slack. Your password doesn’t matter (because it ends up getting reset as you found out). The Team / Organization name must match the one from Slack.

  5. Setup SMTP in Mattermost!

  6. IMPORTANT: Log into your new Mattermost instance and create a second super-user/admin with full privileges!
    You will have to do this via “Invite Members” in the Organization page (using a real email), then via the System Console you need to upgrade that user to a “System Admin”

  7. Import your Slack Data to the new Mattermost Server with the mmctl tool

  8. After the import process is complete Mattermost completely resets your admin user in the Mattermost instance. But it doesn’t reset the second account you created.

  9. Log in with the second account and reset your first account’s password and grant it admin rights again.

All done!

Thanks Jacques. I actually linked a post of yours as my nuclear option above. I’m hoping to find the relevant tables to change to get the permissions right but may have to do as you suggest.

1 Like