Azure WebJob无法启动 [英] Azure WebJob fail to start

查看:113
本文介绍了Azure WebJob无法启动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在Visual Studio 2015中创建了一个Azure WebJob,并将其部署到Azure.

I have created an Azure WebJob in Visual Studio 2015 and deployed it to Azure.

当尝试运行WebJob时,出现此错误:

When trying to run the WebJob I get this error:

[03/12/2017 22:47:46 > 070c62: SYS INFO] Status changed to Running
[03/12/2017 22:47:47 > 070c62: ERR ] 
[03/12/2017 22:47:47 > 070c62: ERR ] Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.VisualStudio.HostingProcess.Utilities.Sync, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
[03/12/2017 22:47:47 > 070c62: ERR ]    at Microsoft.VisualStudio.HostingProcess.EntryPoint.Main()
[03/12/2017 22:47:47 > 070c62: SYS ERR ] Job failed due to exit code -532462766
[03/12/2017 22:47:47 > 070c62: SYS INFO] Process went down, waiting for 60 seconds
[03/12/2017 22:47:47 > 070c62: SYS INFO] Status changed to PendingRestart

我尝试搜索此错误,但找不到与此相关的任何内容.我不知道这是我的WebJob代码还是Azure中WebJob的配置问题.

I have tried to search for this error but can't find anything related to this. I don't know if this is an problem in my WebJob code or the configuration of the WebJob in Azure.

有人对问题的根源有任何想法或指示吗?

Does anyone have some ideas or pointers of where the problem lies?

推荐答案

[03/12/2017 22:47:47> 070c62:ERR]未处理的异常:System.IO.FileNotFoundException:无法加载文件或程序集'Microsoft.VisualStudio.HostingProcess.Utilities.Sync,版本= 14.0.0.0 ,文化=中性,PublicKeyToken = b03f5f7f11d50a3a'或其依赖项之一.该系统找不到指定的文件. [03/12/2017 22:47:47> 070c62:错误]在Microsoft.VisualStudio.HostingProcess.EntryPoint.Main()

[03/12/2017 22:47:47 > 070c62: ERR ] Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.VisualStudio.HostingProcess.Utilities.Sync, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. [03/12/2017 22:47:47 > 070c62: ERR ] at Microsoft.VisualStudio.HostingProcess.EntryPoint.Main()

首先,正如David Ebbo所说,请尝试在Azure Web App沙箱外部运行相同的逻辑,并检查其是否工作正常.

Firstly, as David Ebbo said, please try to run the same logic outside of the Azure Web App sandbox, and check if it works fine.

据我所知,如果WebJobs项目缺少引用的程序集或文件,我们将遇到与您类似的问题.例如,我的控制台应用程序引用了Newtonsoft.Json,但是当我将控制台应用程序作为WebJobs部署到Azure时,我没有包含此文件.

Besides, as far as I know, if the WebJobs project missed the referenced assemblies or files, we would get similar issue as yours. For example, my console application referenced Newtonsoft.Json, but I do not include this file when I deploy console app as WebJobs to Azure, I get below error.

ConsoleApplication13.Program.Main()是我的控制台应用程序的入口点,请检查您的项目以确保您没有丢失某些程序集.

The ConsoleApplication13.Program.Main() is entry point of my console application, please check your project to make sure you did not miss some assemblies.

这篇关于Azure WebJob无法启动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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