gpt4 book ai didi

ASP.NET 4.0 Web 应用程序抛出 "Incorrect function. (Exception from HRESULT: 0x80070001)"

转载 作者:行者123 更新时间:2023-12-02 07:51:06 27 4
gpt4 key购买 nike

该应用程序是用 ASP .NET 4.0 编写的,托管在运行 Windows Server 2008 R2 的计算机上的 IIS 7.5 中。应用程序池正在使用集成托管管道模式。

当在几个没有任何明显共同点的不同页面上时,会引发以下异常。我自己无法重现该异常,但上周在生产环境中发生了 10 次。

从堆栈跟踪中我看到方法“HttpRequest.GetEntireRawContent”引发了异常,所以我想知道请求是否有问题,例如它太长或包含无效字符。

需要明确的是,此异常不是从我编写的代码中抛出,它来自 System.Web 命名空间。所以我无法在它周围添加 try...catch。

如果您能提供有关异常原因或故障排除步骤的任何想法,以了解更多信息,我将不胜感激。

    Exception: System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.Web.HttpException (0x80004005): An error occurred while communicating with the remote host. The error code is 0x80070001. ---> System.Runtime.InteropServices.COMException (0x80070001): Incorrect function. (Exception from HRESULT: 0x80070001)
at System.Web.Hosting.IIS7WorkerRequest.RaiseCommunicationError(Int32 result, Boolean throwOnDisconnect)
at System.Web.Hosting.IIS7WorkerRequest.ReadEntityCoreSync(Byte[] buffer, Int32 offset, Int32 size)
at System.Web.HttpRequest.GetEntireRawContent()
at System.Web.HttpRequest.FillInFormCollection()
at System.Web.HttpRequest.get_Form()
at System.Web.HttpRequest.get_HasForm()
at System.Web.UI.Page.GetCollectionBasedOnMethod(Boolean dontReturnNull)
at System.Web.UI.Page.DeterminePostBackMode()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at ASP.report_openinghours_aspx.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

编辑:

正如卢基弗所指出的,这里有一个类似的问题:stackoverflow.com/questions/7825127/建议的修复方法是关闭 TCP 卸载,我的理解是 TCP 卸载使网络服务器免受 TCP 复杂性的影响。因此关闭它会消耗大量的 CPU 周期,从而降低 Web 服务器的速度,这显然是不可取的。

我也不明白为什么 TCP 卸载会导致 IIS 抛出异常。

最佳答案

您不可能仍然遇到此问题,但如果其他人遇到此问题,这里的链接可能会有所帮助。

TechNet forum

TCP Task Offloading options of the NIC driver should be set at the physicla NIC level (the nic of the host that the External virtual network is using). Be sure that you are not disabling chimney and thinking that you are disabling Task Offloading. In the settings of the driver are options with 'offloading' in the name - these are the options to turn off.

  • Disable Power managment on the phsycial NIC (some drivers turn this on).

  • Try a physical Intel NIC (the least problematic of all with Hyper-V)

  • Check that the ICs in the VM are equal to the host.

  • Check for other issues with the VM such as resource spiking with CPU or disk IO or anything else that might cause a hang.

关于ASP.NET 4.0 Web 应用程序抛出 "Incorrect function. (Exception from HRESULT: 0x80070001)",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8299887/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com