Restoring Teams Data

Restoring Microsoft Teams data can be a challenge given the vast number of places that the data comes from or is stored into. A while back I wrote an article disclosing all of the places that data is stored in Teams. Half the battle with Teams is knowing where the data is. Once you have that foundation you can begin a restore. You’ll need to already be familiar with the information in that article to be successful with this one.

Recently, Microsoft added a new type of channel they call private channels. A private channel is a limited access channel where all members are a subset of the Team in which the channel resides. All Teams channels are stored in SharePoint. But private channels are invisible in SharePoint by default. They wouldn’t be private otherwise. Of course, the admin can change that, but it requires a positive action to do so. This to prevent the stumbling upon private information. The existence of private channels is a game-changer for admins looking to restore data both from policy and procedure perspectives.

Need to know more about private channels? /

Restoring a Teams channel

If the channel was deleted within 30 days, the owner of the Team that it was in can restore it. Here’s how: In the Teams application, press the  next to the team name, then choose Manage team from the menu.

Restoring Microsoft Teams data

Now move to the Channels tab, expand the Deleted list, and press Restore on the channel that you’d like to recover. This will restore the channel exactly as it was before the deletion.

Restoring Microsoft Teams data

Restoring a channel that is within the 30-day limit gets the channel back in its entirety just as it was before the restore. This is ideally how all of your restores should be. As we know, some of your restores won’t be like this. It will have been past the time limit and the restore won’t be this simple or tidy.

We know from my previous article on where data is stored that the files from the channel will be stored in Teams, but the chat will be distributed into Exchange IM messages. You’ll have to manually create a new channel, then restore the data into that channel using the Content search method I describe in that previous article or use a third-party data restore solution. In either case, you won’t be getting the original channel back, but you’ll at least have the data it contained.

Restoring a Team private channel

Private channels are held in their own SharePoint Site Collection due to a limitation on permissioning in SharePoint. Those collections have a special prefix of teamchannel#0 attached to mark them as part of Teams and specifically as a private channel. Even the global admin won’t see that those collections exist unless they are a member.

Your best option for restoring a private channel is the same as for a non-private one. That is, catch it within the first 30 days. If you do, then the channel will be available to restore just as shown above. You’ll know that it’s a private channel because there will be a small lock symbol next to it.

Who can do administration of a private channel?

Restoring Microsoft Teams data

Since we’re talking about private channels, it’s important to know who can restore them. Using the chart below we can see that only the Team owner or the private channel owner can restore the private channel. This, of course, refers to restoring data using the Teams application.

Restoring private channel data

If you are outside of the window for restoring the private channel using the Team app process then there are a couple of additional considerations beyond the standard restore discussed above.
To find all of the messages in a private channel in your content search, you need to include a mailbox from someone on the private channel. This will capture the messages from that channel.

To find all of the data in a private channel in your content search, you need to include the SharePoint site collection of the private channel. Remember, a private channel has its own site collection in SharePoint. It is not in the same collection as the Team.
Finding the URL of the site collection is a bit of a challenge. You’ll need to fire up the SharePoint Online Management Shell and then run the following bit of PowerShell. The SharePoint Online Management Shell can be found here. You’ll want to download and install it.

In the SharePoint Online Management Shell, you need to run the following bit of code. This code will search for collections created using the teamchannel#0 template when displaying the URL for any hidden private channel it finds.

$sites = get-sposite -template "teamchannel#0"
$groupID = “<group_id>"
foreach ($site in $sites) {$x= Get-SpoSite -Identity
$site.url -Detail; if ($x.RelatedGroupId -eq $groupID)

Notice in that bit of code that you need to know the GroupID. To find the GroupID click onto those  for the Team and then choose Get link to team. This will provide you with a URL. Paste that URL and copy out the GroupID from it as shown below.

Now you’re ready to locate the data stored in SharePoint. Perform your data search including the locations for the messages and data using Content Search and restore it into a new channel. It could also be used in an eDiscovery, which gives you more options for downloading the data. Remember though that you can’t convert an existing channel into a private channel so you’ll need to restore the data into a newly created private channel. This means that you’ll need to be a member of the private channel to populate it.

As you can imagine, restoring data and messages into a private channel could bring up all kinds of privacy issues. The channel was private for a reason and is by definition going to contain discussions and/or files that the members didn’t want to make available to anyone else. If I were the admin performing that task, I’d want to see something very clearly in writing indicating that I’m now privy to this information if only by performing the restore. It’s not like you’ll be reading through the data but overseeing something sensitive is just going to happen as part of this process.

Restoring Teams data will never be simple

Restoring Microsoft Teams data will never be easy. The fact is that it’s not simple to restore an ongoing persistent chat and associate the stuff that is stored in other services into the right spots. Teams is a data aggregator and other than messaging doesn’t actually generate much data itself. Instead, everything is available and associated with the app. There’s a lack of metadata, pointers, something that says this file was mentioned here and resided here at this time. So, as admins, our restore process is limited to getting the data but being unable to make it pretty again. The only solution to that problem is to educate your users to report when a channel goes missing quickly. You really don’t want to miss that 30-day window.

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.