How to clear MongoDB to re-activate your workspace

How to clear MongoDB to re-activate your workspace

This is the procedure on how to clear MongoDB data in cases where you have mismatching information and your workspace isn’t working as expected.

Reason/Causes:

You can’t access your workspace and needs to re-register after obtaining a new workspaceToken.

Environment

Self-hosted.

Steps on how to clear MongoDB to re-activate your workspace:

  1. Enter the mongo shell with the command ( this command depends on your deployment type and is different in the case of Docker):

mongo shell

Β 

  1. Chose rocket chat DB:

use rocketchat

Β 

  1. Run the following query ( you should receive successful output where will be statements that a few entries were successfully changed ):

db.rocketchat_settings.remove( {"_id": /Cloud_/} )

Β 

  1. Restart Rocket.Chat server (this is needed for the server to get the refreshed changes on the collection.

Β 

  1. Request for the token from the support agent.

Β 

After all, you will need to pass the registration token which we provide for the workspace under Administration -> connectivity services.