![](/img/trans.png)
[英]Internal Server Error in PowerShell cmdlets for Microsoft Dynamics CRM
[英]Microsoft CRM Dynamics 2011 PowerShell Error when disabling an organization
每當我在 powershell 腳本中嘗試以下行時:
Disable-CrmOrganization -Name MyOrganization
我收到以下錯誤:
Disable-CrmOrganization : The Deployment Service cannot process the request because one or more validation checks failed.
+ Disable-CrmOrganization <<<< -Name MyOrganization
+ CategoryInfo : NotSpecified: (:) [Disable-CrmOrganization], FaultException`1
+ FullyQualifiedErrorId : System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.Deployment.DeploymentServiceFaul
t, Microsoft.Crm.PowerShell, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]],Microsoft.Crm.Pow
erShell.DisableCrmOrganizationCmdlet
但是,如果我手動禁用該組織,則可以毫無問題地執行以下行:
Remove-CrmOrganization -Name MyOrganization
知道為什么我不能用 powershell 禁用組織嗎?
您可能已經瀏覽過此頁面: 使用 PowerShell 調用部署 Web 服務以獲取 CRM PowerShell 參考。
運行此命令會提供其他錯誤詳細信息: $error[0].Exception.Detail.ErrorDetails
此外,Windows 應用程序事件日志顯示錯誤(在我的情況下):
Web 服務請求 FindItems 到報表服務器http://myserver/reportserver/ReportService2005.asmx
失敗並出現 SoapException。 錯誤:授予用戶“NT AUTHORITY\\NETWORK SERVICE”的權限不足以執行此操作。
這讓我看到這篇文章: http : //social.microsoft.com/Forums/en/crm/thread/0dd4a41b-eeba-405c-9b56-c32bfedb9e7a
解決方案是在具有提升權限的帳戶下運行 CrmDeploymentServiceAppPool。 根據帖子在 SQL Server 中作為服務和 sysadmin 登錄。
當我執行 2 次它工作所以嘗試: try { Disable-CrmOrganization -Name "oragnization_name" }catch { Disable-CrmOrganization -Name "oragnization_name" }
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.