Mattermost API Failed to GET teams

Hello Team I’m facing a trouble i can’t use Mattermost course i cant get any Team I’m getting this error.

"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"xxxxxxxxxxxxxxxx","ip_addr":"10.0.1.4","user_id":"xxxxxxxxxxxxxxxxx","method":"GET","err_where":"GetAllTeamsPage","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}

when i call through API i get even i can see my teams in databases but i can call all others API’s, this is just for teams

{
    "id": "app.team.get_all.app_error",
    "message": "We could not get all teams.",
    "detailed_error": "",
    "request_id": "xxxxxxxxxxxxxxxxxx",
    "status_code": 500
}

Hi amani and welcome to the Mattermost forums,

can you please give us a few more details about your setup? Are you running a self hosted environment and if so, what edition in what version? If you’re running a cloud setup, what cloud plan are you on?

Hello agriesser thanks for your replay,

I’m using Mattermost Team edition with version 7.0.0 in Caprover and PostgreSQL version 12.2 i was trying to update so i deploy another Enterprise Edition E0 with version 7.2 when i integrate with old PostgreSQL databases so i start getting that error…

When i restore back-up of PostgreSQL it work fine but it little old i want to recover this this exiting database… i know i did dumb thing starting upgrade without taking recent backup

Hmm… maybe one of the database migrations did not finish. Can you please restart the 7.2 installation and share the whole startup log file then? The logs are usually located in thr logs subfolder of your mattermost installation.

Ideally you would run and watch the command tail -f logs/mattermost.log while you restart the server so you see immediately what‘s going on.

Post the logs here, then - maybe I can see a reason for the problem.
What happens when you start the 7.0 instance again? Are you experiencing the same problems there?

After getting the error in version 7.2 i revert complete to version 7.0 and removed 7.2 but it still showing this error

This are logs for startup

{"timestamp":"2022-09-08 08:57:32.770 Z","level":"debug","msg":"Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:32.941 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:33.307 Z","level":"debug","msg":"Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:33.400 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:34.103 Z","level":"debug","msg":"notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}":"[]"}
{"timestamp":"2022-09-08 08:57:34.193 Z","level":"debug","msg":"Notifications filtered: open: 0, close: 0, reports: 0","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Notifications filtered: open: 0, close: 0, reports: 0":"[]"}
{"timestamp":"2022-09-08 08:57:34.955 Z","level":"debug","msg":"Installing prepackaged plugin","caller":"app/plugin.go:949","path":"/mattermost/prepackaged_plugins/mattermost-plugin-channel-export-v1.0.0-linux-amd64.tar.gz"}
{"timestamp":"2022-09-08 08:57:35.048 Z","level":"debug","msg":"Installing prepackaged plugin","caller":"app/plugin.go:949","path":"/mattermost/prepackaged_plugins/mattermost-plugin-github-v2.0.1-linux-amd64.tar.gz"}
{"timestamp":"2022-09-08 08:57:35.120 Z","level":"debug","msg":"Skipping local installation of plugin since existing version is newer","caller":"app/plugin_install.go:360","plugin_id":"github"}
{"timestamp":"2022-09-08 08:57:35.311 Z","level":"debug","msg":"starting plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"com.mattermost.plugin-channel-export","wrapped_extras":"pathplugins/com.mattermost.plugin-channel-export/server/dist/plugin-linux-amd64args[plugins/com.mattermost.plugin-channel-export/server/dist/plugin-linux-amd64]"}
{"timestamp":"2022-09-08 08:57:35.315 Z","level":"debug","msg":"plugin started","caller":"plugin/hclog_adapter.go:52","plugin_id":"com.mattermost.plugin-channel-export","wrapped_extras":"pathplugins/com.mattermost.plugin-channel-export/server/dist/plugin-linux-amd64pid46"}
{"timestamp":"2022-09-08 08:57:35.315 Z","level":"debug","msg":"waiting for RPC address","caller":"plugin/hclog_adapter.go:52","plugin_id":"com.mattermost.plugin-channel-export","wrapped_extras":"pathplugins/com.mattermost.plugin-channel-export/server/dist/plugin-linux-amd64"}
{"timestamp":"2022-09-08 08:57:35.380 Z","level":"debug","msg":"using plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"com.mattermost.plugin-channel-export","wrapped_extras":"version1"}
{"timestamp":"2022-09-08 08:57:35.384 Z","level":"debug","msg":"plugin address","caller":"plugin/hclog_adapter.go:52","plugin_id":"com.mattermost.plugin-channel-export","wrapped_extras":"address/tmp/plugin692673240networkunixtimestamp2022-09-08T08:57:35.366Z"}
{"timestamp":"2022-09-08 08:57:35.442 Z","level":"debug","msg":"Installing prepackaged plugin","caller":"app/plugin.go:949","path":"/mattermost/prepackaged_plugins/mattermost-plugin-playbooks-v1.25.0-linux-amd64.tar.gz"}
{"timestamp":"2022-09-08 08:57:35.622 Z","level":"debug","msg":"Installing prepackaged plugin","caller":"app/plugin.go:949","path":"/mattermost/prepackaged_plugins/focalboard-v0.15.0-linux-amd64.tar.gz"}
{"timestamp":"2022-09-08 08:57:36.170 Z","level":"debug","msg":"starting plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"playbooks","wrapped_extras":"pathplugins/playbooks/server/dist/plugin-linux-amd64args[plugins/playbooks/server/dist/plugin-linux-amd64]"}
{"timestamp":"2022-09-08 08:57:36.172 Z","level":"debug","msg":"plugin started","caller":"plugin/hclog_adapter.go:52","plugin_id":"playbooks","wrapped_extras":"pathplugins/playbooks/server/dist/plugin-linux-amd64pid53"}
{"timestamp":"2022-09-08 08:57:36.173 Z","level":"debug","msg":"waiting for RPC address","caller":"plugin/hclog_adapter.go:52","plugin_id":"playbooks","wrapped_extras":"pathplugins/playbooks/server/dist/plugin-linux-amd64"}
{"timestamp":"2022-09-08 08:57:36.373 Z","level":"debug","msg":"using plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"playbooks","wrapped_extras":"version1"}
{"timestamp":"2022-09-08 08:57:36.374 Z","level":"debug","msg":"plugin address","caller":"plugin/hclog_adapter.go:52","plugin_id":"playbooks","wrapped_extras":"address/tmp/plugin189916158networkunixtimestamp2022-09-08T08:57:36.373Z"}
{"timestamp":"2022-09-08 08:57:37.052 Z","level":"debug","msg":"starting plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"focalboard","wrapped_extras":"pathplugins/focalboard/server/dist/plugin-linux-amd64args[plugins/focalboard/server/dist/plugin-linux-amd64]"}
{"timestamp":"2022-09-08 08:57:37.053 Z","level":"debug","msg":"plugin started","caller":"plugin/hclog_adapter.go:52","plugin_id":"focalboard","wrapped_extras":"pathplugins/focalboard/server/dist/plugin-linux-amd64pid60"}
{"timestamp":"2022-09-08 08:57:37.053 Z","level":"debug","msg":"waiting for RPC address","caller":"plugin/hclog_adapter.go:52","plugin_id":"focalboard","wrapped_extras":"pathplugins/focalboard/server/dist/plugin-linux-amd64"}
{"timestamp":"2022-09-08 08:57:37.163 Z","level":"debug","msg":"plugin address","caller":"plugin/hclog_adapter.go:52","plugin_id":"focalboard","wrapped_extras":"networkunixaddress/tmp/plugin931360203timestamp2022-09-08T08:57:37.163Z"}
{"timestamp":"2022-09-08 08:57:37.164 Z","level":"debug","msg":"using plugin","caller":"plugin/hclog_adapter.go:52","plugin_id":"focalboard","wrapped_extras":"version1"}
{"timestamp":"2022-09-08 08:57:37.194 Z","level":"info","msg":"connectDatabase","caller":"app/plugin_api.go:928","plugin_id":"focalboard","dbType":"postgres"}
{"timestamp":"2022-09-08 08:57:37.229 Z","level":"debug","msg":"Acquiring cluster lock for Unique IDs migration","caller":"app/plugin_api.go:925","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:37.242 Z","level":"debug","msg":"Releasing cluster lock for Unique IDs migration","caller":"app/plugin_api.go:925","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:37.257 Z","level":"debug","msg":"Mention listener added.","caller":"app/plugin_api.go:925","plugin_id":"focalboard","listener_count":"1"}
{"timestamp":"2022-09-08 08:57:37.258 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifyMentions"}
{"timestamp":"2022-09-08 08:57:37.259 Z","level":"debug","msg":"Starting subscriptions backend","caller":"app/plugin_api.go:925","plugin_id":"focalboard","freq_card":"120","freq_board":"86400"}
{"timestamp":"2022-09-08 08:57:37.259 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifySubscriptions"}
{"timestamp":"2022-09-08 08:57:37.260 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifyLogger"}
{"timestamp":"2022-09-08 08:57:37.262 Z","level":"debug","msg":"notify loop - no hints in queue","caller":"app/plugin_api.go:925","plugin_id":"focalboard","next_check":"\"2022-09-08 09:57:37.262 Z\""}
{"timestamp":"2022-09-08 08:57:37.262 Z","level":"debug","msg":"subscription notifier loop","caller":"app/plugin_api.go:925","plugin_id":"focalboard","next_notify":"\"2022-09-08 09:57:37.262 Z\""}
{"timestamp":"2022-09-08 08:57:37.275 Z","level":"debug","msg":"Fetched template blocks","caller":"app/plugin_api.go:925","plugin_id":"focalboard","count":"7"}
{"timestamp":"2022-09-08 08:57:37.276 Z","level":"debug","msg":"Template import not needed, skipping","caller":"app/plugin_api.go:925","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:37.278 Z","level":"info","msg":"Server.Start","caller":"app/plugin_api.go:928","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:37.279 Z","level":"debug","msg":"server not bind to any port","caller":"app/plugin_api.go:925","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:38.953 Z","level":"debug","msg":"Able to write files to local storage.","caller":"filestore/localstore.go:78"}
{"timestamp":"2022-09-08 08:57:38.959 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:1187"}
{"timestamp":"2022-09-08 08:57:38.959 Z","level":"info","msg":"Server is listening on [::]:8065","caller":"app/server.go:1260","address":"[::]:8065"}
{"timestamp":"2022-09-08 08:57:38.960 Z","level":"debug","msg":"No license provided; Remote Cluster services disabled","caller":"app/server.go:841"}
{"timestamp":"2022-09-08 08:57:59.043 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/system/ping","request_id":"by9ry6iokjn6ur6fen4zngpn1e","status_code":"200"}
{"timestamp":"2022-09-08 08:57:59.564 Z","level":"debug","msg":"Fetching all standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching all standup channels":"[]"}
{"timestamp":"2022-09-08 08:57:59.567 Z","level":"debug","msg":"Found 1 standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Found 1 standup channels":"[]"}
{"timestamp":"2022-09-08 08:57:59.568 Z","level":"debug","msg":"Filtering channels for sending notifications","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Filtering channels for sending notifications":"[]"}
{"timestamp":"2022-09-08 08:57:59.568 Z","level":"debug","msg":"Channels to process: 1","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Channels to process: 1":"[<nil>]"}
{"timestamp":"2022-09-08 08:57:59.568 Z","level":"debug","msg":"Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:59.569 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:59.574 Z","level":"debug","msg":"Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:59.575 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:57:59.578 Z","level":"debug","msg":"notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}":"[]"}
{"timestamp":"2022-09-08 08:57:59.578 Z","level":"debug","msg":"Notifications filtered: open: 0, close: 0, reports: 0","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Notifications filtered: open: 0, close: 0, reports: 0":"[]"}
{"timestamp":"2022-09-08 08:58:10.324 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/select_team","request_id":"w8u6yrbgtfrtxc63bdbcbhigmo","status_code":"200"}
{"timestamp":"2022-09-08 08:58:14.128 Z","level":"info","msg":"Post.Message has size restrictions","caller":"sqlstore/post_store.go:2262","max_characters":16383,"max_bytes":65535}
{"timestamp":"2022-09-08 08:58:14.131 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/license/client","request_id":"prduhnd9838s5py4sgdmqagdyh","status_code":"200"}
{"timestamp":"2022-09-08 08:58:14.135 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/config/client","request_id":"qunms5pcaifwfpofw53spb1dqe","status_code":"200"}
{"timestamp":"2022-09-08 08:58:14.970 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/users/me/preferences","request_id":"pkyrw34ugjdkpqgi953rh7whic","status_code":"200"}
{"timestamp":"2022-09-08 08:58:14.978 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/users/me/teams/members","request_id":"sym1n9a1y7rsxxzypqqr4uep8y","status_code":"200"}
{"timestamp":"2022-09-08 08:58:14.981 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/users/me","request_id":"iefcmoojttn18m3kex1tqhojhc","status_code":"304"}
{"timestamp":"2022-09-08 08:58:14.981 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/users/me/teams","request_id":"q8cdaweu37yyibxpqyyq64yg3w","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetTeamsForUser","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:58:14.981 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/users/me/teams","request_id":"q8cdaweu37yyibxpqyyq64yg3w","status_code":"500"}
{"timestamp":"2022-09-08 08:58:15.351 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"POST","url":"/api/v4/roles/names","request_id":"ru9rq8zh53dtxmjdh3i4hqfpoy","status_code":"200"}
{"timestamp":"2022-09-08 08:58:15.357 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"POST","url":"/api/v4/roles/names","request_id":"5u8at348apyu5jg4qj6ad1cpow","status_code":"200"}
{"timestamp":"2022-09-08 08:58:15.491 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/plugins/webapp","request_id":"jr4ziko1ujnmbxnmmq6wd1imua","status_code":"200"}
{"timestamp":"2022-09-08 08:58:15.502 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/users/me/teams/unread","request_id":"nq69yduhz7gm3nw767ingjyg1w","status_code":"200"}
{"timestamp":"2022-09-08 08:58:18.137 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"POST","url":"/api/v4/roles/names","request_id":"ak8kuqj743rwxkoq9j4i53pync","status_code":"200"}
{"timestamp":"2022-09-08 08:58:18.187 Z","level":"debug","msg":"New request:","caller":"app/plugin_api.go:925","plugin_id":"com.github.matterpoll.matterpoll","Host":"factss.apps.vannahplus.com","RequestURI":"/plugins/com.github.matterpoll.matterpoll/api/v1/configuration","Method":"GET"}
{"timestamp":"2022-09-08 08:58:18.245 Z","level":"info","msg":"reminder preference is empty. Defaulting to \"on\"","caller":"app/plugin_api.go:928","plugin_id":"com.mattermost.plugin-todo"}
{"timestamp":"2022-09-08 08:58:19.843 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"i31m4rhopby6zjoujhoij97rhw","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetAllTeamsPageWithCount","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:58:19.843 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/teams","request_id":"i31m4rhopby6zjoujhoij97rhw","status_code":"500"}
{"timestamp":"2022-09-08 08:58:19.910 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/analytics/old","request_id":"y8wozrmbifbm7j3b8fzormigha","status_code":"200"}
{"timestamp":"2022-09-08 08:58:20.232 Z","level":"debug","msg":"New request:","caller":"app/plugin_api.go:925","plugin_id":"com.github.matterpoll.matterpoll","Host":"factss.apps.vannahplus.com","RequestURI":"/plugins/com.github.matterpoll.matterpoll/api/v1/configuration","Method":"GET"}
{"timestamp":"2022-09-08 08:58:24.600 Z","level":"debug","msg":"Fetching all standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching all standup channels":"[]"}
{"timestamp":"2022-09-08 08:58:24.603 Z","level":"debug","msg":"Found 1 standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Found 1 standup channels":"[]"}
{"timestamp":"2022-09-08 08:58:24.604 Z","level":"debug","msg":"Filtering channels for sending notifications","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Filtering channels for sending notifications":"[]"}
{"timestamp":"2022-09-08 08:58:24.604 Z","level":"debug","msg":"Channels to process: 1","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Channels to process: 1":"[<nil>]"}
{"timestamp":"2022-09-08 08:58:24.604 Z","level":"debug","msg":"Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:24.604 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:24.608 Z","level":"debug","msg":"Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:24.609 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:24.612 Z","level":"debug","msg":"notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}":"[]"}
{"timestamp":"2022-09-08 08:58:24.613 Z","level":"debug","msg":"Notifications filtered: open: 0, close: 0, reports: 0","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Notifications filtered: open: 0, close: 0, reports: 0":"[]"}
{"timestamp":"2022-09-08 08:58:29.220 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/system/ping","request_id":"gx7mab11mjdmidg4nu55um7a5e","status_code":"200"}
{"timestamp":"2022-09-08 08:58:29.593 Z","level":"debug","msg":"Scheduling Job","caller":"migrations/scheduler.go:45","scheduler":"migrations"}
{"timestamp":"2022-09-08 08:58:29.596 Z","level":"debug","msg":"All migrations are complete.","caller":"migrations/scheduler.go:84","scheduler":"migrations"}
{"timestamp":"2022-09-08 08:58:29.599 Z","level":"debug","msg":"Next run time for scheduler","caller":"jobs/schedulers.go:147","scheduler_name":"migrations","next_runtime":"<nil>"}
{"timestamp":"2022-09-08 08:58:49.705 Z","level":"debug","msg":"Fetching all standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching all standup channels":"[]"}
{"timestamp":"2022-09-08 08:58:49.711 Z","level":"debug","msg":"Found 1 standup channels","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Found 1 standup channels":"[]"}
{"timestamp":"2022-09-08 08:58:49.712 Z","level":"debug","msg":"Filtering channels for sending notifications","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Filtering channels for sending notifications":"[]"}
{"timestamp":"2022-09-08 08:58:49.712 Z","level":"debug","msg":"Channels to process: 1","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Channels to process: 1":"[<nil>]"}
{"timestamp":"2022-09-08 08:58:49.714 Z","level":"debug","msg":"Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Processing channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:49.715 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:49.729 Z","level":"debug","msg":"Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:49.730 Z","level":"debug","msg":"Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Fetching standup config for channel: 618rmw4e4pbsdbq5zz7dkjm8by":"[]"}
{"timestamp":"2022-09-08 08:58:49.745 Z","level":"debug","msg":"notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","notification status for channel: 618rmw4e4pbsdbq5zz7dkjm8by, &{true true true}":"[]"}
{"timestamp":"2022-09-08 08:58:49.746 Z","level":"debug","msg":"Notifications filtered: open: 0, close: 0, reports: 0","caller":"app/plugin_api.go:925","plugin_id":"standup-raven","Notifications filtered: open: 0, close: 0, reports: 0":"[]"}
{"timestamp":"2022-09-08 08:58:59.370 Z","level":"debug","msg":"Received HTTP request","caller":"web/handlers.go:156","method":"GET","url":"/api/v4/system/ping","request_id":"5gm4ikpqopffjpr8q89opspxjw","status_code":"200"}

The above one is server the bellow one is inside in system console

{"timestamp":"2022-09-08 08:48:39.755 Z","level":"info","msg":"SimpleWorker: Job is complete","caller":"jobs/base_workers.go:88","worker":"ExpiryNotify","job_id":"tbjoim68ypn6dyhyrji5z1qwfh"}
{"timestamp":"2022-09-08 08:51:53.469 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/users/me/teams","request_id":"4dadoe1tjbdnzkrn8tjs7q3mmy","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetTeamsForUser","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:51:56.769 Z","level":"info","msg":"reminder preference is empty. Defaulting to \"on\"","caller":"app/plugin_api.go:928","plugin_id":"com.mattermost.plugin-todo"}
{"timestamp":"2022-09-08 08:51:59.703 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"rgx3gks6ipyh5qooedtb6amr5y","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetAllTeamsPageWithCount","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:52:50.592 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"16osn3dym3fq5n18bdmeo7hbsy","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetAllTeamsPage","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:52:50.969 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"h6bfr3dtg7gqxeng5cmpfgpbyw","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetAllTeamsPageWithCount","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:57:21.830 Z","level":"info","msg":"Stopping Server...","caller":"app/server.go:946"}
{"timestamp":"2022-09-08 08:57:21.838 Z","level":"info","msg":"stopping websocket hub connections","caller":"app/web_hub.go:113"}
{"timestamp":"2022-09-08 08:57:21.909 Z","level":"info","msg":"Stopped workers","caller":"jobs/workers.go:90"}
{"timestamp":"2022-09-08 08:57:21.909 Z","level":"info","msg":"Stopping schedulers.","caller":"jobs/schedulers.go:118"}
{"timestamp":"2022-09-08 08:57:21.909 Z","level":"info","msg":"Schedulers stopped.","caller":"jobs/schedulers.go:50"}
{"timestamp":"2022-09-08 08:57:21.915 Z","level":"info","msg":"Server stopped","caller":"app/server.go:1026"}
{"timestamp":"2022-09-08 08:57:21.916 Z","level":"info","msg":"Shutting down plugins","caller":"app/plugin.go:339"}
{"timestamp":"2022-09-08 08:57:22.012 Z","level":"info","msg":"Server.Shutdown","caller":"app/plugin_api.go:928","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:29.324 Z","level":"info","msg":"Server is initializing...","caller":"app/server.go:255","go_version":"go1.16.7"}
{"timestamp":"2022-09-08 08:57:29.325 Z","level":"info","msg":"Starting websocket hubs","caller":"app/web_hub.go:93","number_of_hubs":4}
{"timestamp":"2022-09-08 08:57:29.326 Z","level":"info","msg":"Pinging SQL","caller":"sqlstore/store.go:215","database":"master"}
{"timestamp":"2022-09-08 08:57:29.395 Z","level":"warn","msg":"The database schema version and model versions do not match","caller":"sqlstore/upgrade.go:146","schema_version":"6.7.0","model_version":"6.5.2"}
{"timestamp":"2022-09-08 08:57:29.422 Z","level":"info","msg":"Loaded system translations","caller":"i18n/i18n.go:93","for locale":"en","from locale":"/mattermost/i18n/en.json"}
{"timestamp":"2022-09-08 08:57:29.449 Z","level":"info","msg":"Current version is 6.5.2 (6.5.2-rc1/Thu Jun 2 19:48:41 UTC 2022/557e10fed10c7acddb2f893cfa739532c66671a8/none)","caller":"app/server.go:538","current_version":"6.5.2","build_number":"6.5.2-rc1","build_date":"Thu Jun 2 19:48:41 UTC 2022","build_hash":"557e10fed10c7acddb2f893cfa739532c66671a8","build_hash_enterprise":"none"}
{"timestamp":"2022-09-08 08:57:29.449 Z","level":"info","msg":"Team Edition Build","caller":"app/server.go:549","enterprise_build":false}
{"timestamp":"2022-09-08 08:57:29.449 Z","level":"info","msg":"Printing current working","caller":"app/server.go:553","directory":"/mattermost"}
{"timestamp":"2022-09-08 08:57:29.449 Z","level":"info","msg":"Loaded config","caller":"app/server.go:554","source":"file:///mattermost/config/config.json"}
{"timestamp":"2022-09-08 08:57:29.470 Z","level":"info","msg":"Starting workers","caller":"jobs/workers.go:48"}
{"timestamp":"2022-09-08 08:57:29.473 Z","level":"info","msg":"Starting schedulers.","caller":"jobs/schedulers.go:47"}
{"timestamp":"2022-09-08 08:57:29.528 Z","level":"error","msg":"License key from https://mattermost.com required to unlock enterprise features.","caller":"app/license.go:90","error":"resource: License id: "}
{"timestamp":"2022-09-08 08:57:29.681 Z","level":"info","msg":"Starting up plugins","caller":"app/plugin.go:185"}
{"timestamp":"2022-09-08 08:57:29.682 Z","level":"info","msg":"Syncing plugins from the file store","caller":"app/plugin.go:259"}
{"timestamp":"2022-09-08 08:57:29.705 Z","level":"info","msg":"Syncing plugin from file store","caller":"app/plugin.go:319","bundle":"plugins/com.mattermost.plugin-todo.tar.gz"}
{"timestamp":"2022-09-08 08:57:29.705 Z","level":"info","msg":"Syncing plugin from file store","caller":"app/plugin.go:319","bundle":"plugins/standup-raven.tar.gz"}
{"timestamp":"2022-09-08 08:57:29.714 Z","level":"info","msg":"Syncing plugin from file store","caller":"app/plugin.go:319","bundle":"plugins/github.tar.gz"}
{"timestamp":"2022-09-08 08:57:29.724 Z","level":"info","msg":"Syncing plugin from file store","caller":"app/plugin.go:319","bundle":"plugins/com.github.matterpoll.matterpoll.tar.gz"}
{"timestamp":"2022-09-08 08:57:31.590 Z","level":"warn","msg":"ignored duplicate step name","caller":"app/plugin_api.go:934","plugin_id":"github","name":"oauth-info","flow":"oauth"}
{"timestamp":"2022-09-08 08:57:37.194 Z","level":"info","msg":"connectDatabase","caller":"app/plugin_api.go:928","plugin_id":"focalboard","dbType":"postgres"}
{"timestamp":"2022-09-08 08:57:37.258 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifyMentions"}
{"timestamp":"2022-09-08 08:57:37.259 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifySubscriptions"}
{"timestamp":"2022-09-08 08:57:37.260 Z","level":"info","msg":"Initialized notification backend","caller":"app/plugin_api.go:928","plugin_id":"focalboard","name":"notifyLogger"}
{"timestamp":"2022-09-08 08:57:37.278 Z","level":"info","msg":"Server.Start","caller":"app/plugin_api.go:928","plugin_id":"focalboard"}
{"timestamp":"2022-09-08 08:57:38.959 Z","level":"info","msg":"Starting Server...","caller":"app/server.go:1187"}
{"timestamp":"2022-09-08 08:57:38.959 Z","level":"info","msg":"Server is listening on [::]:8065","caller":"app/server.go:1260","address":"[::]:8065"}
{"timestamp":"2022-09-08 08:58:14.128 Z","level":"info","msg":"Post.Message has size restrictions","caller":"sqlstore/post_store.go:2262","max_characters":16383,"max_bytes":65535}
{"timestamp":"2022-09-08 08:58:14.981 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/users/me/teams","request_id":"q8cdaweu37yyibxpqyyq64yg3w","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetTeamsForUser","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}
{"timestamp":"2022-09-08 08:58:18.245 Z","level":"info","msg":"reminder preference is empty. Defaulting to \"on\"","caller":"app/plugin_api.go:928","plugin_id":"com.mattermost.plugin-todo"}
{"timestamp":"2022-09-08 08:58:19.843 Z","level":"error","msg":"We could not get all teams.","caller":"web/context.go:105","path":"/api/v4/teams","request_id":"i31m4rhopby6zjoujhoij97rhw","ip_addr":"10.0.1.4","user_id":"jq6x175m8fn15n5krrnt7pwqdh","method":"GET","err_where":"GetAllTeamsPageWithCount","http_code":500,"err_details":"failed to find Teams: missing destination name cloudlimitsarchived in *[]*model.Team"}

Your system is running on 6.5.2, not on 7.0.0 and also the database schema does not match the binary you’re using now.
We need to find out what database schema version you’re currently running and then we need to start the matching binary.

Please connect to your database and run the following command to find out what the latest database migration ID is that got applied:

mm720=# select * from db_migrations order by version DESC LIMIT 1;
 version |     name
---------+--------------
      90 | create_enums
(1 row)

(This is an example on my 7.2.0 installation with schema ID 90).

I restored this corrupted db to one of my testing mattermost i wasn’t check the version of it but sure it is 6.5.2 as the picture bellow
Screenshot from 2022-09-12 07-55-57

but this database was corrupted in mattermost version 7.0.0 see the picture below, i just restored old db to this version because our team still need to communicate while i need to recover this db, even though the error was the same from version 6.5.2 and 7.0.0
Screenshot from 2022-09-12 07-56-10

and this db provide this to that command

mattermost=# select * from db_migrations order by version DESC LIMIT 1;
 version |     name     
---------+--------------
      90 | create_enums
(1 row)

Not sure if I fully understand, sorry.
You do have two instances running now, the production one on 7.0.0 with database schema version 85 (as per your second screenshot) and a demo one on 6.5.2-rc1 with database schema version 6.5.2.

The SQL query you ran that showed the version to be 90 contradicts both of your screenshots - it should read “85” on the 7.0.0 install, actually, since this is also what you’re seeing in the GUI.

If the query has been run on the same database that is used by your 7.0.0 installation which shows the DB schema version to be 85, then please stop this instance, login to the PostgreSQL server and run the following command:

DELETE FROM db_migrations WHERE version >= 85;

Start your mattermost instance again, it should try to re-apply the schema migrations from ID 85 upwards.
Please monitor the mattermost.log file to see if there are any errors with the schema migration and if you see some, please share them in your next post.

Thanks so much i just also tried to install 7.2.1 and restore that databases worked fine i think the issues was database schema Version:
Screenshot from 2022-09-12 10-46-39

Also is there documentation that show which databases schema version are required to Mattermost Version

OK, great - so you did now run the delete query on the migrations table and that helped?
I haven’t found an overview for that so far, but I’m always using the GitHub repository for that:

You can filter by tag there and scroll down to the bottom to see the DB schema version for this Mattermost version:

grafik

Hi, Yes, that helped with the delete query in migrations, but I just deleted it because it was an old version, so I just fired up a new version of mattermost and the import database worked perfectly.

So far, the conclusion I’ve reached is that the database schema and mattermost versions were incompatible.

Thank you so much for your assistance and time spent resolving my problem.