How to configure ASP. NET programs on X64 System

Source: Internet
Author: User

The default value of ASP. NET is Any CPU during compilation, that is, the compiled program can run on X86 and X64 system platforms. If you want your ASP. NET program to run on the X64 system, all you have to do is deploy IIS and modify the configuration.

If you want to run the program in IIS32-Bit mode, that is, to run the program in. net framwork32-Bit mode, perform the following Configuration:

1. cscript % systemdrive % inetpubadminscriptsadsutil. vbs set w3svc/appPools/enable32bitapponwin64 1 modify the IIS configuration and allow 32-bit programs to run

2. windowsMicrosoft. NETFrameworkv2.0.50727aspnet _ regiis-I registers asp. net32 for IIS. After registration, Asp. net2.0. * 32bit is displayed in the web extension of IIS.

3. Web extensions allow Asp. net2.0. * 32 bit to run. The w3wp32.exe process is running.

Ii. 64-Bit mode

1. cscript % systemdrive % inetpubadminscriptsadsutil. vbs set w3svc/appPools/enable32bitapponwin64 0 is 0 by default. If a 32-bit program is run, you need to reset it to 0.

2. windowsMicrosoft. NETFramework64v2.0.50727aspnet _ regiis-I registers 64 for IIS as Asp. NET. IIS registered with 64-bit ASP. NET displays Asp. net2.0. * in the Web extension .*.

3. The Web extension allows Asp. net2.0. * to run. The w3wp.exe process is running.

About Compilation: As mentioned at the beginning, the general default Compiling is Any CPU, that is, the program supports X86 and X64 by default. However, I have not tested whether there is any performance loss, but theoretically I think there will be a loss rate. If you want to learn more about this, please provide some information. When testing, I run the X86 compiled program on X64. The result shows that I tried to load a 64-bit assembly on a 32-bit platform. If the Assembly is loaded for reflection purposes, use ReflectionOnlyLoad () instead (). I learned a valuable experience!

References

<

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.