Monthly Archives: January 2018

We’ve run into a problem with your Office 365 subscription after tenant to tenant migration.

After a tenant to tenant migration multiple people got the message ‘We’ve run into a problem with your Office 365 subscription’.

I found a script wroted by someone on;
How to resolve “We’ve run into a problem with your Office 365 subscription” with PowerShell

So to resolve this issue you start powershell on the PC that has the problems and run the following command.
set-executionpolicy unrestricted

Then create an .ps1 file with the following code

<# .SYNOPSIS This script locates OSPP.vbs and removes all product keys to trigger O365 reactivation. It will remove ALL product keys. .NOTES File Name: Author : Johan Dahlbom, johan[at] Blog : The script is provided “AS IS” with no guarantees, no warranties, and they confer no rights. #>
#Check that the script runs with privileged rights
if (-not([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) {
Write-Warning "You need to have Administrator rights to run this script!`nPlease re-run this script as an Administrator in an elevated powershell prompt!"
#Find OSPP.vbs path and run the command with the dstatus option (Last 1...)
$OSPP = Resolve-Path -Path "C:\Program Files*\Microsoft Offic*\Office*\ospp.vbs" | Select-Object -ExpandProperty Path -Last 1
Write-Output -InputObject "OSPP Location is: $OSPP"
$Command = "cscript.exe '$OSPP' /dstatus"
$DStatus = Invoke-Expression -Command $Command

#Get product keys from OSPP.vbs output.
$ProductKeys = $DStatus | Select-String -SimpleMatch "Last 5" | ForEach-Object -Process { $_.tostring().split(" ")[-1]}

if ($ProductKeys) {
Write-Output -InputObject "Found $(($ProductKeys | Measure-Object).Count) productkeys, proceeding with deactivation..."
#Run OSPP.vbs per key with /unpkey option.
foreach ($ProductKey in $ProductKeys) {
Write-Output -InputObject "Processing productkey $ProductKey"
$Command = "cscript.exe '$OSPP' /unpkey:$ProductKey"
Invoke-Expression -Command $Command
} else {
Write-Output -InputObject "Found no keys to remove... "

Then you can launch the script via powershell and all should be fine.