“启用 32 位应用程序"时无法访问服务设置为真 [英] Service not accessible when "Enable 32-Bit Applications" set to true

查看:20
本文介绍了“启用 32 位应用程序"时无法访问服务设置为真的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在开发服务器上我使用的是 IIS 版本 7.5.7600.16385

On the development server I use IIS Veresion 7.5.7600.16385

为 .Net 4.5.1 编译的服务,任何 CPU

And a Service compiled for .Net 4.5.1, Any CPU

该服务在开发服务器(Win Server 2008 R2)上运行良好.

The service works fine on the development server (Win Server 2008 R2).

在客户端的生产服务器上但是我遇到了奇怪的问题:

On the client's production server however I get strange problems:

(相同的IIS版本,相同的操作系统版本)

(Same IIS Version, same OS version)

一旦我设置了启用 32 位应用程序",该服务的 URL 就不再能在浏览器中访问.(页面不可用)

As soon as I set "Enable 32-Bit Applications" the service's URL is no longer accessible in a browser. (Page not available)

(我需要 32Bit 模式,因为该服务使用了一些遗留的 COM 组件)

(I need the 32Bit mode because the service uses some legacy COM components)

什么可能导致这个问题?

What may cause this problems?

有什么想法、提示、建议吗?

Any ideas, hints, suggestions?

<人力资源>编辑

更多详情:

IIS 工作进程"作为w3wp.exe *32"运行

The "IIS Worker Process" is running as "w3wp.exe *32"

在同一个应用程序池中有一个 ClickOnce 安装,其行为相同:在 64 位下工作正常,如果 32 位设置为 true,则无法访问.

There is a ClickOnce Installation in the same Application Pool which behaves the same: works ok in 64 bit, not accessible if 32Bit set to true.

事实上,这个 32Bit App-Pool 的所有页面都产生了相同的行为 (HTTP 500) 页面未找到.

In fact all pages of this 32Bit App-Pool produce the same behaviour (HTTP 500) page not found.

推荐答案

步骤 1:在 IIS 中启用登录

为了在 IIS 中启用更好的错误消息和日志文件,您必须安装两个功能:

In Order to enable better error messages and log files in IIS you must install two Features:

控制面板->程序和功能->打开或关闭Windows功能

Control Panel->Programs and Features->Turn Windows features on or off

您需要安装两个功能:

WebServer->常见 Http 功能->HTTP 错误

WebServer->Common Http Features->HTTP Errors

WebServer->健康与诊断->HTTP 日志记录

WebServer-> Health an Diagnostics->HTTP Logging

第 2 步:分析错误消息

启用 HTTP 错误后,当我访问 32 位应用程序池中的任何页面时,我收到一条更详细的消息:

With HTTP Errors enabled I got a more verbose message when I accessed any page in the 32Bit App Pool:

HTTP 错误 500.19

HTTP Error 500.19

动态压缩模块

错误代码 0x8007007e

ErrorCode 0x8007007e

第 3 步:解码错误代码

我使用了 Microsoft Exchange Server 错误代码查找 将 ErrorCode 转换为更有用的内容:

I used Microsoft Exchange Server Error Code Look-up to convert the ErrorCode into something more useful:

C:Userscombyte>err 0x8007007e

C:Userscombyte>err 0x8007007e

作为 HRESULT:严重性:失败 (1),设施:0x7,代码 0x7e

as an HRESULT: Severity: FAILURE (1), Facility: 0x7, Code 0x7e

...

ERROR_MOD_NOT_FOUND winerror.h

ERROR_MOD_NOT_FOUND winerror.h

找不到指定的模块.

事实证明,未安装特定的 DLL.就我而言,WSUS(Windows 服务器更新服务)的安装仅安装了 64 位版本的 DynamicCompressionModule (C:Windowssystem32inetsrvsuscomp.dll).

It turned out, that a specific DLL was not installed. In my case the installation of WSUS (Windows Server Update Services) installed a 64Bit version of DynamicCompressionModule (C:Windowssystem32inetsrvsuscomp.dll) only.

解决方案 1

使用以下命令从 IIS 配置中删除/禁用 XPress 压缩方案(对于所有页面/应用程序池):

Remove/Disable the XPress compression scheme from the IIS configuration (for all pages/app-pools) using this command:

%windir%system32inetsrvappcmd.exe set config -section:system.webServer/httpCompression /-[name='xpress']

解决方案 2

禁用在 IIS 配置文件 C:WindowsSystem32inetsrvconfigApplicationHost.config 中加载 xpress 模块用于 32Bit App-Pools:

Disable loading of the xpress module in IIS config file C:WindowsSystem32inetsrvconfigApplicationHost.config for 32Bit App-Pools:

部分中将属性 preCondition="bitness64" 添加到 xpress 模块:

add attribute preCondition="bitness64" to the xpress module in section <modules>:

<add name="DynamicCompressionModule" lockItem="true" preCondition="bitness64" />

解决方案 3

suscomp.dll 的 32 位版本(来自 WSUS 的 32 位安装)安装到 %windir%SYSWOW64inetsrv

Install the 32Bit version of suscomp.dll(from a 32 Bit Installation of WSUS) into %windir%SYSWOW64inetsrv

这篇关于“启用 32 位应用程序"时无法访问服务设置为真的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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