Which .net core 5 runtime is preferred x86 or x64?

Tanul 1,281 Reputation points
2021-01-06T12:48:06.017+00:00

Team,

Happy NewYear!

On my azure environment, I want to host .net core 5 rest api on this machine

Previous generation A-Series
53975-untitled.png

On this azure machine(part of my service plan) 4 other services are already running where in 1% CPU + 47.44% RAM is already consumed.

Need to add here that I have made this api on my local machine which has 64-bit OS with 8 GB ram.

Which .net core 5 environment should I install as extension in azure app service(32-bit or 64-bit).

Kindly suggest.

Thank you

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,978 questions
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,600 questions
Azure Stack Hub
Azure Stack Hub
An extension of Azure for running apps in an on-premises environment and delivering Azure services in a datacenter.
189 questions
.NET Runtime
.NET Runtime
.NET: Microsoft Technologies based on the .NET software framework.Runtime: An environment required to run apps that aren't compiled to machine language.
1,166 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,888 questions
0 comments No comments
{count} votes

Accepted answer
  1. Michael Taylor 54,731 Reputation points
    2021-01-06T15:00:56.077+00:00

    Unless there is a reason not to I'd use x64. Gives you access to more memory if you need it. The cost should be the same as all the Azure App Services are 64-bit processors anyway. Compile your code as Any CPU and it run on either. The only time I'd probably drop down to x86 is if I needed to run software that wasn't supported on x64 (say native C++ code that only had x86 libraries).

    3 people found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. KalyanChanumolu-MSFT 8,336 Reputation points
    2021-01-06T14:58:51.64+00:00

    @Tanul Thank you for reaching out.
    If you are running a 64-bit operating system, you should compile your code for 64-bit and use the 64-bit runtime.

    A major benefit of .Net core is that you don't need to install the runtime on your server.
    You can bundle it along with your application itself.

    Use the below command to generate a self contained app

    dotnet publish -r win-x64  
    

    Please let us know if you have further questions.

    1 person found this answer helpful.

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.