应用程序配置失败,并且“找不到可信应用程序的WMI类”。 [英] Application Provisioning fails with "The WMI classes for trusted applications were not found."

查看:61
本文介绍了应用程序配置失败,并且“找不到可信应用程序的WMI类”。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个与OCS 2007服务器通信的Web服务应用程序,并使用UserEndpoint类检索用户状态信息。当我在IIS服务器上与OCS在同一个盒子上部署应用程序时,它可以正常工作。但是当我尝试将其部署在远程计算机上然后尝试连接到OCS服务器时,它会失败并出现以下异常:

DeregisterReason =无
Microsoft.Rtc.Signaling.RegisterException:多次尝试后操作失败。
  在Microsoft.Rtc.Signaling.SipAsyncResult`1.ThrowIfFailed()
  在Microsoft.Rtc.Signaling.Helper.EndAsyncOperation [T](对象所有者,IAsyncResult结果)
  在Microsoft.Rtc.Collaboration.LocalEndpoint.EndEstablish(IAsyncResult结果)
  在OCSWebService.Session.EndpointEstablishCompleted(IAsyncResult的结果)在C:\Documents和Settings\Administrator\My Documents\Visual工作室2008\Projects\OCSTesting\OCSWebService\Session.cs:线130
  在System.Environment.GetStackTrace检测到(例外e,布尔需要文件信息)
  在System.Environment.get_StackTrace()
   at Microsoft.Rtc.Signaling.RealTimeException..ctor(String message,Exception innerException)
   at Microsoft.Rtc.Signaling.FailureResponseException..ctor(String message,Exception innerException,SipResponseData responseData)
   at Microsoft.Rtc.Signaling.Helper.CreateExceptionByType(String message,SipResponseData responseData,Exception innerException,Type exceptionType)
  在Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.CheckForTooManyTransactions()
  在Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.ProcessCore()
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.ProcessAuthenticationRequiredResponse(SipResponse response)
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.Transaction_ResponseReceived(Object sender,ResponseReceivedEventArgs e)
  在Microsoft.Rtc.Internal.Sip.OutgoingNonInviteTransaction.OnResponseReceived(EventArgs e)
  在Microsoft.Rtc.Internal.Sip.DispatchEventWorkitem.Execute()
  在Microsoft.Rtc.Internal.Sip.SingleThreadedDispatcherQueue.DispatcherCallback(对象队列)
  在System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallback tpWaitCallBack)
  在System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(对象状态)

所以我想我可能需要配置我的应用程序(如果我错了,请纠正我)。所以我使用了以下的ApplicationProvisioning API

            TrustedApplicationPool trustedApplicationPool = TrustedApplicationPool.GetApplicationPoolForServer(_userServer,_applicationName);
            TrustedService trustedService = trustedApplicationPool.GetTrustedServiceForLocalMachine();
            X509Certificate2 cert = null;
            X509Store Store = new X509Store(StoreName.My,StoreLocation.LocalMachine);
            Store.Open(OpenFlags.ReadOnly | OpenFlags.OpenExistingOnly);

            foreach(X509Certificate2 Store.Certificates中的证书)
            {
                if(Certificate.Subject == _userServer)
                {
&n&n;                  //在这里挑选正确的证书我只有一个证书安装,所以没有检查那个                   ;  cert =证书;
                }            }            Store.Close();

            if(trustedService!= null)
            {
                ServerPlatformSettings clientPlatformSettings =新ServerPlatformSettings(_applicationName,trustedService.Fqdn,trustedService.Port,trustedService.Gruu,CERT);
           &NBSP ;    _collabPlatform = new CollaborationPlatform(clientPlatformSettings);                _collabPlatform.BeginStartup(PlatformStartupCompleted,null);
                Console.WriteLine("启动平台。");

           但是我在TrustedApplicationPool.GetApplicationPoolForServer调用上遇到错误,说"找不到可信应用程序的WMI类。"。我在这里错过了一步吗?

解决方案

希望这有帮助...

http://msdn.microsoft。 com / zh-CN / library / dd253360%28office.13%29.aspx

http://blogs.msdn.com/cmayo/archive/2010/01/22/how-to-provision -a-ucma-2-0-application-for-office-communications-server-2007-r2.aspx

http://blogs.msdn.com/cmayo/archive/2010/02/ 18 / establish-a-ucma-2-0-collaborationplatform-and-applicationendpoint-using-application-provisioner-exe-settings.aspx

玩得开心。

I am creating a webservice application that talks to OCS 2007 server and retrieves users presence information using UserEndpoint class. When I deploy the application on the IIS server on the same box as the OCS it works fine. But when I try to deploy it on a remote machine and then try to connect to the OCS server it fails with the below exception:

DeregisterReason=None
Microsoft.Rtc.Signaling.RegisterException: The operation failed after several attempts.
   at Microsoft.Rtc.Signaling.SipAsyncResult`1.ThrowIfFailed()
   at Microsoft.Rtc.Signaling.Helper.EndAsyncOperation[T](Object owner, IAsyncResult result)
   at Microsoft.Rtc.Collaboration.LocalEndpoint.EndEstablish(IAsyncResult result)
   at OCSWebService.Session.EndpointEstablishCompleted(IAsyncResult result) in C:\Documents and Settings\Administrator\My Documents\Visual Studio 2008\Projects\OCSTesting\OCSWebService\Session.cs:line 130
   Detected at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)
   at System.Environment.get_StackTrace()
   at Microsoft.Rtc.Signaling.RealTimeException..ctor(String message, Exception innerException)
   at Microsoft.Rtc.Signaling.FailureResponseException..ctor(String message, Exception innerException, SipResponseData responseData)
   at Microsoft.Rtc.Signaling.Helper.CreateExceptionByType(String message, SipResponseData responseData, Exception innerException, Type exceptionType)
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.CheckForTooManyTransactions()
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.ProcessCore()
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.ProcessAuthenticationRequiredResponse(SipResponse response)
   at Microsoft.Rtc.Signaling.SipTransactionAsyncResult`1.Transaction_ResponseReceived(Object sender, ResponseReceivedEventArgs e)
   at Microsoft.Rtc.Internal.Sip.OutgoingNonInviteTransaction.OnResponseReceived(EventArgs e)
   at Microsoft.Rtc.Internal.Sip.DispatchEventWorkitem.Execute()
   at Microsoft.Rtc.Internal.Sip.SingleThreadedDispatcherQueue.DispatcherCallback(Object queue)
   at System.Threading._ThreadPoolWaitCallback.PerformWaitCallbackInternal(_ThreadPoolWaitCallback tpWaitCallBack)
   at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback(Object state)

So I figured that may be I need to provision my application (correct me if I am wrong here). So I used the ApplicationProvisioning API as below

            TrustedApplicationPool trustedApplicationPool = TrustedApplicationPool.GetApplicationPoolForServer(_userServer, _applicationName);
            TrustedService trustedService = trustedApplicationPool.GetTrustedServiceForLocalMachine();
            X509Certificate2 cert = null;
            X509Store Store = new X509Store(StoreName.My, StoreLocation.LocalMachine);
            Store.Open(OpenFlags.ReadOnly | OpenFlags.OpenExistingOnly);

            foreach (X509Certificate2 Certificate in Store.Certificates)
            {
                if (Certificate.Subject == _userServer)
                {
                    //Pick up correct certificate here. I have only one cert install so not checking for that
                    cert = Certificate;
                }
            }

            Store.Close();

            if (trustedService != null)
            {
                ServerPlatformSettings clientPlatformSettings = new ServerPlatformSettings(_applicationName, trustedService.Fqdn, trustedService.Port, trustedService.Gruu, cert);
                _collabPlatform = new CollaborationPlatform(clientPlatformSettings);
                _collabPlatform.BeginStartup(PlatformStartupCompleted, null);
                Console.WriteLine("Starting the platform.");

            }

But I get error on the TrustedApplicationPool.GetApplicationPoolForServer call saying "The WMI classes for trusted applications were not found.". Am I missing a step here?

解决方案

Hope this helps...

http://msdn.microsoft.com/en-us/library/dd253360%28office.13%29.aspx

http://blogs.msdn.com/cmayo/archive/2010/01/22/how-to-provision-a-ucma-2-0-application-for-office-communications-server-2007-r2.aspx

http://blogs.msdn.com/cmayo/archive/2010/02/18/establishing-a-ucma-2-0-collaborationplatform-and-applicationendpoint-using-application-provisioner-exe-settings.aspx


Have fun.


这篇关于应用程序配置失败,并且“找不到可信应用程序的WMI类”。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆