开发用于Windows Server 2003 64位的Windows XP 32位 [英] Developing for Windows Server 2003 64 bit on Windows XP 32 bit

查看:172
本文介绍了开发用于Windows Server 2003 64位的Windows XP 32位的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在开发基于Windows XP专业版的ASP.NET应用程序。同时促进生产我只是现在发现该服务器是64位。我安装了Oracle客户端32位服务器上,并不能连接到Oracle。

I have been developing an ASP.NET application on Windows XP Professional. While promoting to production I have only now found out that the server is 64 bit. I installed Oracle Client 32 bit on the server and cannot connect to Oracle.

我使用的是微软提供的甲骨文,和我的问题是,我怎么编一个32位计算机上的ASP.NET应用程序连接到Oracle在Windows Server 2003 64位机?

I am using the Microsoft Provider for Oracle, and my question is, how do I get an ASP.NET application compiled on a 32 bit machine to connect to Oracle on a Windows Server 2003 64 bit machine?

编辑:

在回答关于我原来的问题评论,我得到的错误是尝试加载Oracle客户端库扔BadImageFormatException,将在64位模式下安装了32位Oracle客户端组件运行时,会出现此问题

In response to a comment on my original question, the error I am getting is "Attempt to load Oracle client libraries threw BadImageFormatException. This problem will occur when running in 64 bit mode with the 32 bit Oracle client components installed"

我已经卸载了32位客户端,并正在逐渐安装了64位客户端,但问题是该服务器是在DMZ中的生产服务器,我必须在服务器自己进不去了,所以我试图预见任何问题安装了64位客户端时,我会和我尝试访问ASP.NET应用程序在服务器上

I have uninstalled the 32 bit client and am getting the 64 bit client installed, the problem is that the server is a production server in a DMZ and I have no access to the server myself, so I am trying to anticipate any problems I will have when the 64 bit client is installed and I try to access the ASP.NET application on the server

推荐答案

简单的解决办法:你应该根据平台(64一64机)安装Oracle客户端。其原因是,.NET应用程序很可能要建在值为anycpu配置,这意味着它将作为在x64平台上64位应用程序运行。然后,它只能加载64位本机库...

Straightforward solution : you should install the Oracle client according to the platform (x64 on a x64 machine). The reason is that your .NET application is very likely to be built in AnyCPU configuration, which means it will run as a x64 application on a x64 platform. It then can only load x64 native libraries...

请注意,当涉及到Oracle,我喜欢用 Oracle即时客户

Note that when it comes to Oracle, I like to use Oracle Instant Client :

  • 您不必在目标机器(包括开发框!)。安装任何软件
  • 您可以确保您的应用程序将与特定的客户端,你挑(版本,在x86 / x64)上运行。
  • 您甚至可以轻松拥有多个应用程序在同一台计算机上的不同的客户端版本。
  • 作为一个缺点,它增加了一个显著的重量为你的应用程序(19MB〜最小)。

检查<一href="http://stackoverflow.com/questions/70602/what-is-the-minimum-client-footprint-required-to-connect-c-to-an-oracle-database/70901#70901">What所需的最小客户端资源占用连接C#来Oracle数据库?了解详情。

在您的特定情况下,我建议建立一个Visual Studio项目,将工作在x86以及x64的机器:检查我的博客文章的 Oracle即时客户端在Visual Studio 。那么这里是指导如何进行配置WiX的包Oracle即时客户端的针对x86或x64机器。如果使用其他部署策略,只要确保你根据目标平台出货正确的客户端。

In your particular case, I recommend setting up a Visual Studio project that will work on x86 as well as x64 machines : check my blog post Oracle Instant Client in Visual Studio. Then here is a guidance on how to configure a WiX package for Oracle Instant Client targeting x86 or x64 machines. If you use another deployment strategy, just make sure you ship the correct client according to the target platform.

这篇关于开发用于Windows Server 2003 64位的Windows XP 32位的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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