Concluiu toda a instalação da Bimer API, mas no final, ao tentar acessar o sevidor e porta a mensagem "Erro de Servidor no Aplicativo '/'." está sendo apresentada?
Veja a seguir o que fazer para solucionar...
Mensagem (na íntegra)
Erro de Servidor no Aplicativo '/'.
O acesso ao caminho 'C:\inetpub\wwwroot\BimerAPIBimerAPI\log' foi negado.
Descrição: Ocorreu uma exceção sem tratamento durante a execução da atual solicitação da Web. Examine o rastreamento de pilha para obter mais informações sobre o erro e onde foi originado no código.
Detalhes da Exceção: System.UnauthorizedAccessException: O acesso ao caminho 'C:\inetpub\wwwroot\BimerAPIBimerAPI\log' foi negado.
Solução
O ASP.NET não está autorizado a acessar o recurso solicitado.
Recomenda-se conceder à identidade de solicitação do ASP.NET direitos de acesso ao recurso. O ASP.NET tem uma identidade de processo-base (geralmente {MACHINE}\ASPNET no IIS 5 ou Serviço de Rede no IIS 6 e IIS 7, e a identidade de pool do aplicativo configurada no IIS 7.5) que é usada se o aplicativo não estiver sendo representado. Se o aplicativo estiver sendo representado através de <identity impersonate="true"/>, a identidade será o usuário anônimo (geralmente IUSR_MACHINENAME) ou o usuário de solicitação autenticado.
Para conceder ao ASP.NET acesso a um arquivo, clique com o botão direito do mouse no arquivo no Explorador de Arquivos, escolha "Propriedades" e selecione a guia Segurança. Clique em "Adicionar" para adicionar o usuário ou grupo apropriado. Realce a conta ASP.NET e procure o acesso desejado nas caixas.
Erro de Origem:
|
|
Rastreamento de Pilha:
|
[UnauthorizedAccessException: O acesso ao caminho 'C:\inetpub\wwwroot\BimerAPIBimerAPI\log' foi negado.] System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +417 System.IO.Directory.InternalCreateDirectory(String fullPath, String path, Object dirSecurityObj, Boolean checkHost) +1394 System.IO.Directory.InternalCreateDirectoryHelper(String path, Boolean checkHost) +92 Alterdata.ERP.Aplicacao.Servico.Implementacao.Base.ConfiguradorBimerAPI..ctor() in C:\jenkins\slave\workspace\Bimer\DSE-WEB-BimerAPI.WebService\ServicoAplicacao\Implementacao\Base\ConfiguradorBimerAPI.cs:36 AlterdataBimerWebAPI.Startup.Configuration(IAppBuilder app) in C:\jenkins\slave\workspace\Bimer\DSE-WEB-BimerAPI.WebService\WebAPI\Startup.cs:42 [TargetInvocationException: Uma exceção foi acionada pelo destino de uma chamada.] System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) +0 System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) +128 System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +142 Owin.Loader.<>c__DisplayClass12.<MakeDelegate>b__b(IAppBuilder builder) +93 Owin.Loader.<>c__DisplayClass1.<LoadImplementation>b__0(IAppBuilder builder) +212 Microsoft.Owin.Host.SystemWeb.OwinAppContext.Initialize(Action`1 startup) +873 Microsoft.Owin.Host.SystemWeb.OwinBuilder.Build(Action`1 startup) +51 Microsoft.Owin.Host.SystemWeb.OwinHttpModule.InitializeBlueprint() +101 System.Threading.LazyInitializer.EnsureInitializedCore(T& target, Boolean& initialized, Object& syncLock, Func`1 valueFactory) +135 Microsoft.Owin.Host.SystemWeb.OwinHttpModule.Init(HttpApplication context) +160 System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +580 System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +165 System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +267 System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +341 [HttpException (0x80004005): Uma exceção foi acionada pelo destino de uma chamada.] System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +523 System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +107 System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +688 |
Informações sobre a Versão: Microsoft .NET Framework Versão:4.0.30319; Versão do ASP.NET:4.7.3282.0