Notitie
Voor toegang tot deze pagina is autorisatie vereist. U kunt proberen u aan te melden of de directory te wijzigen.
Voor toegang tot deze pagina is autorisatie vereist. U kunt proberen de mappen te wijzigen.
Symptomen
Wanneer u de wisselknop Nieuwe Teams uitproberen inschakelt in de klassieke Versie van Microsoft Teams, wordt de nieuwe Teams-app niet gestart. In plaats daarvan wordt een banner weergegeven en wordt het volgende foutbericht weergegeven:
Er is iets verkeerd gegaan.
Als u het logboekbestand voor klassieke Teams controleert, wordt de volgende foutvermelding geregistreerd:
message: Launch api returns false, code: 11, apiCode: undefined, extendedErrorCode: 0, launchStatus: failed, status: failure, scenario: <scenarioGUID>, scenarioName: launch_pear_app, name: launch_pear_app
Oorzaak
Dit probleem kan om een van de volgende redenen optreden:
- De mappen cookies en cacheshell verwijzen naar een reparsepunt.
- De TEMP - of TMP-omgevingsvariabelen wijzen naar een reparsepunt.
- U hebt geen leesmachtiging voor toegang tot bepaalde mappen in de map AppData .
- Sommige mappen in de map AppData worden gewijzigd om te functioneren als reparsepunten.
- De map AppData bevat ongeldige bestanden met dezelfde naam als de vereiste systeemmappen.
- Het SYSTEEM-account en de groep Administrators hebben niet de machtiging Volledig beheer voor bepaalde mappen in de map AppData .
- U beschikt niet over de SYSAPPID-machtiging voor de installatielocatie van Teams.
- De beleidsinstelling AllowAllTrustedApps voorkomt dat nieuwe Teams worden gestart.
Oplossing
Als u de juiste oplossing voor dit probleem wilt toepassen, moet u meerdere controles uitvoeren om de oorzaak van het probleem te bepalen. Er zijn twee opties om alle benodigde diagnostische controles uit te voeren. Gebruik de gewenste optie.
Optie 1: Een script uitvoeren
Het PowerShell-script TeamsLaunchCheck.ps1 automatiseert alle controles die u moet uitvoeren.
Het script TeamsLaunchCheck.ps1
# $erroractionpreference="stop"
$list = @(
"$env:APPDATA",
"$env:APPDATA\Microsoft",
"$env:APPDATA\Microsoft\Crypto",
"$env:APPDATA\Microsoft\Internet Explorer",
"$env:APPDATA\Microsoft\Internet Explorer\UserData",
"$env:APPDATA\Microsoft\Internet Explorer\UserData\Low",
"$env:APPDATA\Microsoft\Spelling",
"$env:APPDATA\Microsoft\SystemCertificates",
"$env:APPDATA\Microsoft\Windows",
"$env:APPDATA\Microsoft\Windows\Libraries",
"$env:APPDATA\Microsoft\Windows\Recent",
"$env:LOCALAPPDATA",
"$env:LOCALAPPDATA\Microsoft",
"$env:LOCALAPPDATA\Microsoft\Windows",
"$env:LOCALAPPDATA\Microsoft\Windows\Explorer",
"$env:LOCALAPPDATA\Microsoft\Windows\History",
"$env:LOCALAPPDATA\Microsoft\Windows\History\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\History\Low\History.IE5",
"$env:LOCALAPPDATA\Microsoft\Windows\IECompatCache",
"$env:LOCALAPPDATA\Microsoft\Windows\IECompatCache\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\IECompatUaCache",
"$env:LOCALAPPDATA\Microsoft\Windows\IECompatUaCache\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCache",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies\DNTException",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies\DNTException\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies\PrivacIE",
"$env:LOCALAPPDATA\Microsoft\Windows\INetCookies\PrivacIE\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\PPBCompatCache",
"$env:LOCALAPPDATA\Microsoft\Windows\PPBCompatCache\Low",
"$env:LOCALAPPDATA\Microsoft\Windows\PPBCompatUaCache",
"$env:LOCALAPPDATA\Microsoft\Windows\PPBCompatUaCache\Low",
"$env:LOCALAPPDATA\Microsoft\WindowsApps",
"$env:LOCALAPPDATA\Packages",
"$env:LOCALAPPDATA\Publishers",
"$env:LOCALAPPDATA\Publishers\8wekyb3d8bbwe",
"$env:LOCALAPPDATA\Temp",
"$env:USERPROFILE\AppData\LocalLow",
"$env:USERPROFILE\AppData\LocalLow\Microsoft",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer\DOMStore",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer\EdpDomStore",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer\EmieSiteList",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer\EmieUserList",
"$env:USERPROFILE\AppData\LocalLow\Microsoft\Internet Explorer\IEFlipAheadCache"
)
$ver = Get-ItemProperty -Path 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\'
$script:osVersion = $ver.DisplayVersion
if($script:osVersion -eq "") {
$script:osVersion = $ver.ReleaseId
}
$script:osBuild = (Get-WmiObject -Class Win32_OperatingSystem).Version
$script:osUBR= [int]$ver.UBR
$script:osFullBuild = [version]"$script:osBuild.$script:osUBR"
$script:osProductName = $ver.ProductName
function ValidateShellFolders
{
$shellFolders = @(
"Cookies",
"Cache"
)
$shellPaths = @{}
$path = "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders"
$keys = Get-Item $path
$props = Get-ItemProperty $path
($keys).Property | %{
$shellPaths[$_] = $props."$_"
$str = $props."$_"
$str += "`t: " + $_
echo $str
}
foreach($shellFolder in $shellFolders)
{
$shellPath = $shellPaths[$shellFolder]
if(PathContainsReparsePoint($shellPath))
{
Write-Warning "$($shellFolder) User Shell Folder path $shellPath contains a reparse point."
}
else
{
Write-Host "$($shellFolder) User Shell Folder path $shellPath is not a reparse point" -ForegroundColor Green
}
}
}
function ValidateEnvironmentVars
{
$temps = (gci env:* | ?{@("TEMP", "TMP").Contains($_.Name)})
foreach($temp in $temps)
{
if(PathContainsReparsePoint($temp.Value))
{
Write-Warning "$($temp.Name): $($temp.Value) contains a reparse point."
}
else
{
Write-Host "$($temp.Name): $($temp.Value) is not a reparse point" -ForegroundColor Green
}
}
}
function ValidateUserAccess($list)
{
$checked = @()
foreach ($path in $list)
{
$left = $path
for($i=0;$i -lt 10; $i++)
{
if ([string]::IsNullOrEmpty($left))
{
break;
}
if(-Not $checked.Contains($left))
{
try
{
if (Test-Path -Path $left)
{
$items = Get-ChildItem $left -ErrorAction SilentlyContinue -ErrorVariable GCIErrors
if($GCIErrors.Count -eq 0)
{
Write-Host "User is able to access $left" -ForegroundColor Green
}
else
{
Write-Warning "$left is missing permissions for the current user."
}
$checked += $left
}
else
{
Write-Host "MISSING: $path" -ForegroundColor Green
}
}
catch
{
Write-Warning "Error trying to access $left."
}
}
$left=Split-Path $left
}
}
}
function ValidatePaths($list)
{
foreach ($path in $list)
{
if (Test-Path -Path $path)
{
if (Test-Path -Path $path -PathType Container)
{
Write-Host "Folder: $path" -ForegroundColor Green
}
else
{
Write-Warning "FILE: $path"
}
}
else
{
Write-Host "MISSING: $path" -ForegroundColor Green
}
}
}
function ValidateSystemPerms($list)
{
foreach ($path in $list)
{
if (Test-Path -Path $path)
{
$systemPerms = (Get-Acl $path).Access | where {$_.IdentityReference -eq "NT AUTHORITY\SYSTEM"}
$systemFullControl = $systemPerms | where {$_.FileSystemRights -eq "FullControl" -and $_.AccessControlType -eq "Allow"}
if($systemFullControl.Count -ge 1)
{
Write-Host "$path has the correct permissions assigned for SYSTEM account" -ForegroundColor Green
}
else
{
Write-Warning "$path is missing permissions for the SYSTEM account. The current permissions:"
$systemPerms
}
$adminPerms = (Get-Acl $path).Access | where {$_.IdentityReference -eq "BUILTIN\Administrators"}
$adminFullControl = $adminPerms | where {$_.FileSystemRights -eq "FullControl" -and $_.AccessControlType -eq "Allow"}
if($adminFullControl.Count -ge 1)
{
Write-Host "$path has the correct permissions assigned for Administrators group" -ForegroundColor Green
}
else
{
Write-Warning "$path is missing permissions for the Administrators group. The current permissions:"
$adminPerms
}
}
else
{
Write-Host "MISSING: $path" -ForegroundColor Green
}
}
}
function ValidateSysAppIdPerms
{
$apps = Get-AppxPackage MSTeams
foreach($app in $apps)
{
$perms = (Get-Acl $app.InstallLocation).sddl -split "\(" | ?{$_ -match "WIN:/\/\SYSAPPID"}
if($perms.Length -gt 0)
{
Write-Host "$($app.InstallLocation) has the correct SYSAPPID permissions assigned" -ForegroundColor Green
}
else
{
Write-Warning "$($app.InstallLocation) is missing SYSAPPID permissions."
}
}
}
function IsReparsePoint([string]$path)
{
$props = Get-ItemProperty -Path $path -ErrorAction SilentlyContinue
if($props.Attributes -match 'ReparsePoint')
{
return $true
}
return $false
}
function PathContainsReparsePoint($path, $trace = $false)
{
$badPaths = 0
$result = ""
$left = $path
for($i=0;$i -lt 10; $i++)
{
if ([string]::IsNullOrEmpty($left))
{
break;
};
if(IsReparsePoint($left))
{
$result = "Y" + $result
$badPaths++
}
else{
$result = "N" + $result
}
$left=Split-Path $left
}
if($trace)
{
if ($result.Contains("Y"))
{
Write-Warning "$result $path contains a reparse point"
}
else
{
Write-Host "$result $path" -ForegroundColor Green
}
}
return $badPaths -gt 0
}
function ValidateAppXPolicies()
{
$osPatchThresholds = @{
"10.0.19044" = 4046 #Win 10 21H2
"10.0.19045" = 3636 #Win 10 22H2
"10.0.22000" = 2777 #Win 11 21H2
"10.0.22621" = 2506 #Win 11 22H2
}
$minPatchVersion = [version]"10.0.19044"
$maxPatchVersion = [version]"10.0.22621"
if($script:osFullBuild -lt $minPatchVersion)
{
if(-Not (HasAllowAllTrustedAppsKeyEnabled))
{
Write-Warning "AllowAllTrustedApps is not enabled and OS version is too low to get the AllowAllTrustedApps patch."
}
else
{
Write-Host "The OS version is too low to get the AllowAllTrustedApps patch, but AllowAllTrustedApps is a supported value" -ForegroundColor Green
}
}
elseif($script:osFullBuild -le $maxPatchVersion)
{
$targetUBR = $osPatchThresholds[$script:osBuild]
if($script:osUBR -lt $targetUBR)
{
if(-Not (HasAllowAllTrustedAppsKeyEnabled))
{
$recommendedVersion = [version]"$script:osBuild.$targetUBR"
Write-Warning "AllowAllTrustedApps is not enabled and your version of Windows does not contain a required patch to support this.`nEither update your version of Windows to be greater than $recommendedVersion, or enable AllowAllTrustedApps"
}
else
{
Write-Host "OS version is missing the AllowAllTrustedApps patch, but AllowAllTrustedApps is a supported value" -ForegroundColor Green
}
}
else
{
Write-Host "OS version has the AllowAllTrustedApps patch" -ForegroundColor Green
}
}
else
{
Write-Host "OS version is high enough that AllowAllTrustedApps should not be an issue" -ForegroundColor Green
}
}
function HasAllowAllTrustedAppsKeyEnabled
{
$hasKey = $false;
$appXKeys = @("HKLM:\Software\Microsoft\Windows\CurrentVersion\AppModelUnlock", "HKLM:\Software\Policies\Microsoft\Windows\Appx")
foreach ($key in $appXKeys)
{
try
{
$value = Get-ItemPropertyValue -Path $key -Name "AllowAllTrustedApps"
echo "$key AllowAllTrustedApps = $value"
if ($value -ne 0)
{
$hasKey = $true
break;
}
}
catch
{
echo "Missing AllowAllTrustedApps key at $key"
}
}
return $hasKey
}
echo "$script:osProductName Version $script:osVersion, Build $script:osFullBuild"
echo ""
echo "# Checking for reparse points in user shell folders"
ValidateShellFolders
echo ""
echo "# Checking for reparse points in temp/tmp environment variables"
ValidateEnvironmentVars
echo ""
echo "# Checking for user permissions in appdata"
ValidateUserAccess($list)
echo ""
echo "# Checking for reparse points in appdata"
foreach ($path in $list)
{
$result = PathContainsReparsePoint $path $true
}
echo ""
echo "# Checking for unexpected files in appdata"
ValidatePaths($list)
echo ""
echo "# Checking SYSTEM and Administrators permissions in appdata"
ValidateSystemPerms($list)
echo ""
echo "# Checking SYSAPPID permissions"
ValidateSysAppIdPerms
echo ""
echo "# Checking if AllowAllTrustedApps is valid"
ValidateAppXPolicies
Pause
Optie 2: De controles handmatig uitvoeren
Belangrijk
Deze sectie, methode of taak bevat stappen voor het bewerken van het register. Als u het register op onjuiste wijze wijzigt, kunnen er echter grote problemen optreden. Zorg er daarom voor dat u de volgende stappen zorgvuldig volgt. Maak voor extra beveiliging een back-up van het register voordat u het wijzigt. U kunt dan het register herstellen als er een probleem optreedt.
Controleer of de mappen cookies en cacheshell verwijzen naar een locatie die een reparsepunt is:
Voer de volgende PowerShell-opdrachten uit:
(gp ([environment]::getfolderpath("Cookies"))).Attributes -match 'ReparsePoint' (gp ([environment]::getfolderpath("InternetCache"))).Attributes -match 'ReparsePoint'
Als beide opdrachten Onwaar retourneren, gaat u naar stap 2. Anders opent u de Register-editor en zoekt u de volgende subsleutel:
Computer\HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders
Werk voor de shell-map in de PowerShell-opdracht die wordt geretourneerd als Waar, de waarde van de bijbehorende registervermelding bij naar een locatie die geen reparsepunt is. U kunt bijvoorbeeld de waarde instellen op het standaardpad:
Registervermelding Waarde Cookies %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies
Cache %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCache
Controleer of de waarden van de omgevingsvariabelen TEMP of TMP zijn ingesteld op een reparsepunt:
Voer de volgende PowerShell-opdracht uit:
gci env:* | ?{@("TEMP", "TMP").Contains($_.Name)} | %{$_.Value+" - "+((gp $_.Value).Attributes -match 'ReparsePoint')}
Als de opdracht False retourneert, gaat u naar stap 3. Anders stelt u de waarde van de omgevingsvariabelen in op een locatie die geen reparsepunt is.
Controleer of u de leesmachtiging hebt voor toegang tot alle volgende mappen in de map AppData :
- %USERPROFILE%\AppData\Local
- %USERPROFILE%\AppData\Local\Microsoft
- %USERPROFILE%\AppData\Local\Microsoft\Windows
- %USERPROFILE%\AppData\Local\Microsoft\Windows\Explorer
- %USERPROFILE%\AppData\Local\Microsoft\Windows\History
- %USERPROFILE%\AppData\Local\Microsoft\Windows\History\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\History\Low\History.IE5
- %USERPROFILE%\AppData\Local\Microsoft\Windows\IECompatCache
- %USERPROFILE%\AppData\Local\Microsoft\Windows\IECompatCache\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\IECompatUaCache
- %USERPROFILE%\AppData\Local\Microsoft\Windows\IECompatUaCache\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCache
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies\DNTException
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies\DNTException\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies\PrivacIE
- %USERPROFILE%\AppData\Local\Microsoft\Windows\INetCookies\PrivacIE\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\PPBCompatCache
- %USERPROFILE%\AppData\Local\Microsoft\Windows\PPBCompatCache\Low
- %USERPROFILE%\AppData\Local\Microsoft\Windows\PPBCompatUaCache
- %USERPROFILE%\AppData\Local\Microsoft\Windows\PPBCompatUaCache\Low
- %USERPROFILE%\AppData\Local\Microsoft\WindowsApps
- %USERPROFILE%\AppData\Local\Packages
- %USERPROFILE%\AppData\Local\Packages\VirtualizationTests.Main_8wekyb3d8bbwe\LocalCache
- %USERPROFILE%\AppData\Local\Publishers
- %USERPROFILE%\AppData\Local\Publishers\8wekyb3d8bbwe
- %USERPROFILE%\AppData\Local\Temp
- %USERPROFILE%\AppData\LocalLow
- %USERPROFILE%\AppData\LocalLow\Microsoft
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer\DOMStore
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer\EdpDomStore
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer\EmieSiteList
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer\EmieUserList
- %USERPROFILE%\AppData\LocalLow\Microsoft\Internet Explorer\IEFlipAheadCache
- %USERPROFILE%\AppData\Roaming
- %USERPROFILE%\AppData\Roaming\Microsoft
- %USERPROFILE%\AppData\Roaming\Microsoft\Crypto
- %USERPROFILE%\AppData\Roaming\Microsoft\Internet Explorer
- %USERPROFILE%\AppData\Roaming\Microsoft\Internet Explorer\UserData
- %USERPROFILE%\AppData\Roaming\Microsoft\Internet Explorer\UserData\Low
- %USERPROFILE%\AppData\Roaming\Microsoft\Spelling
- %USERPROFILE%\AppData\Roaming\Microsoft\SystemCertificates
- %USERPROFILE%\AppData\Roaming\Microsoft\Windows
- %USERPROFILE%\AppData\Roaming\Microsoft\Windows\Libraries
- %USERPROFILE%\AppData\Roaming\Microsoft\Windows\Recent
U kunt de PowerShell-opdracht Test-Path gebruiken om deze controle uit te voeren. Als u niet over de leesmachtiging voor een bepaalde map beschikt, vraagt u iemand met de machtiging Volledig beheer voor de map om u de machtiging Lezen te verlenen.
Controleer of een van de mappen die worden vermeld in stap 3, worden gewijzigd om te functioneren als reparsepunten. Als een van de mappen reparsepunten zijn, neemt u contact op Microsoft Ondersteuning.
Controleer op bestanden met dezelfde naam als een vereiste systeemmap in de map AppData . Een bestand met de naam Bibliotheken in het pad, %AppData%\Microsoft\Windows\Libraries, heeft bijvoorbeeld dezelfde naam als een map met hetzelfde pad. Voer voor elke map die wordt vermeld in stap 3 de volgende PowerShell-opdracht uit:
Test-Path -Path <directory name, such as $env:USERPROFILE\AppData\Local\Temp> -PathType Leaf
Als de opdracht True retourneert, verwijdert u het bestand en maakt u een map met dezelfde naam als het volledige pad voor de systeemmap.
Controleer of het SYSTEM-account en de groep Administrators de machtiging Volledig beheer hebben voor alle mappen die worden vermeld in stap 3.
Voer de volgende PowerShell-opdrachten uit voor elke map:
((Get-Acl (Join-Path $env:USERPROFILE "<directory name that starts with AppData, such as AppData\Local>")).Access | ?{$_.IdentityReference -eq "NT AUTHORITY\SYSTEM" -and $_.FileSystemRights -eq "FullControl"} | measure).Count -eq 1 ((Get-Acl (Join-Path $env:USERPROFILE "<directory name that starts with AppData, such as AppData\Local>")).Access | ?{$_.IdentityReference -eq "BUILTIN\Administrators" -and $_.FileSystemRights -eq "FullControl"} | measure).Count -eq 1
Als een van de opdrachten Onwaar retourneert, vraagt u iemand die de machtiging Volledig beheer heeft voor de map om de machtiging Volledig beheer toe te kennen aan het bijbehorende account.
Controleer of u de SYSAPPID-machtiging hebt voor de installatielocatie van Teams. Voer de volgende PowerShell-opdracht uit:
Get-AppxPackage MSTeams | %{$_.InstallLocation+" - "+(((Get-Acl $_.InstallLocation).sddl -split "\(" | ?{$_ -match "WIN:/\/\SYSAPPID"} | Measure).count -eq 1)}
Als de opdracht False retourneert, vraagt u een lid van de lokale groep Administrators om uw gebruikersprofiel op de computer te verwijderen. Meld u vervolgens aan met uw gebruikersaccount om het gebruikersprofiel opnieuw te maken.
Controleer de beleidsinstelling AllowAllTrustedApps :
Voer de
winver
opdracht uit in een opdrachtpromptvenster.Vergelijk uw Windows-versie en buildnummer in de resultaten met de volgende versies van Windows 11 en Windows 10:
- Windows 11 versie 21H2 OS build 22000.2777
- Windows 11 versie 22H2 OS build 22621.2506
- Windows 10 versie 21H2 OS build 19044.4046
- Windows 10 versie 22H2 OS build 19045.3636
Als uw Windows-versie en buildnummer ouder zijn dan die in de lijst, opent u registereditor en zoekt u de registervermelding AllowAllTrustedApps onder een van de volgende subsleutels:
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\AppModelUnlock
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Appx
Controleer de waarde van AllowAllTrustedApps. Als de waarde 0 is, wordt het beleid uitgeschakeld. Wijzig deze in 1 om het beleid in te schakelen en probeer het vervolgens opnieuw om nieuwe Teams te starten.
Opmerking: als u nieuwe Teams wilt starten zonder het beleid AllowAllTrustedApps in te schakelen, moet u een van de versies van Windows uitvoeren die worden vermeld in stap 5b.
Als het probleem zich blijft voordoen, werkt u het systeem bij naar Windows 11, versie 22H2, os build 22621.2506 of een latere versie.