1
我收到錯誤「無法刪除用戶'[email protected]'。」在Azure和Office 365錯誤中「不是所有選定的用戶都被刪除了某些用戶目前無法刪除相關標識:」。Azure用戶刪除錯誤
我已經運行以下與幾個O365技術,它只是不會刪除。這是不以任何共享資源,聯繫人列表,DLIST等
PS C:\Users\owner> set-executionpolicy unrestricted
Execution Policy Change
The execution policy helps protect you from scripts that you do not trust. Changing the execution policy might expose
you to the security risks described in the about_Execution_Policies help topic. Do you want to change the execution
policy?
[Y] Yes [N] No [S] Suspend [?] Help (default is "Y"):
PS C:\Users\owner> $Cred = Get-Credential
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $Cred -Authentication Basic –AllowRedirection
Import-PSSession $Session
PS C:\Users\owner> Remove-MsolUser -UserPrincipalName [email protected]
Confirm
Continue with this operation?
[Y] Yes [N] No [S] Suspend [?] Help (default is "Y"):
Remove-MsolUser : Unable to complete this action. Try again later.
At line:1 char:16
+ Remove-MsolUser <<<< -UserPrincipalName [email protected]
+ CategoryInfo : OperationStopped: (:) [Remove-MsolUser], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.InternalServiceException,Microsoft.Online.Adm
inistration.Automation.RemoveUser
PS C:\Users\owner> remove-msoldomain -domainname user.com -force
Remove-MsolDomain : Unable to remove this domain. Use Get-MsolUser -DomainName <domain name> to retrieve a list of obj
ects that are blocking removal.
At line:1 char:18
+ remove-msoldomain <<<< -domainname user.com -force
+ CategoryInfo : OperationStopped: (:) [Remove-MsolDomain], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.DomainNotEmptyException,Microsoft.Online.Admi
nistration.Automation.RemoveDomain
PS C:\Users\owner> get-msoluser -domainname user.com
UserPrincipalName DisplayName isLicensed
----------------- ----------- ----------
[email protected] User A. Name False
PS C:\Users\owner> remove-msoluser -userprincipalname [email protected]
Confirm
Continue with this operation?
[Y] Yes [N] No [S] Suspend [?] Help (default is "Y"):
Remove-MsolUser : Unable to complete this action. Try again later.
At line:1 char:16
+ remove-msoluser <<<< -userprincipalname [email protected]
+ CategoryInfo : OperationStopped: (:) [Remove-MsolUser], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.InternalServiceException,Microsoft.Online.Adm
inistration.Automation.RemoveUser
PS C:\Users\owner> remove-msoluser -userprincipalname [email protected] -force
Remove-MsolUser : Unable to complete this action. Try again later.
At line:1 char:16
+ remove-msoluser <<<< -userprincipalname [email protected] -force
+ CategoryInfo : OperationStopped: (:) [Remove-MsolUser], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.InternalServiceException,Microsoft.Online.Adm
inistration.Automation.RemoveUser
我確定這已經被問到了,但只是爲了涵蓋所有的基礎:你不是想刪除你登錄的用戶,是嗎? –