Programming Languages on Power

 View Only

Announcing .NET 8 on IBM Power

By Janani Janakiraman posted Mon November 20, 2023 11:52 AM

  

IBM®, Microsoft®, and Red Hat® recently announced the availability of .NET 8, with delivery included in RHEL 8.9, RHEL 9.3, and Red Hat OpenShift. This release also provides support for Linux on Power (ppc64le) and IBM Z systems (s390x). .NET 8 succeeds .NET 7, which was introduced for the first time approximately a year ago. This version is a long-term support release of .NET.

In addition to being a long-term support release, .NET 8 comes with feature enhancements and bug fixes. The software development kit (SDK) supports the use of the latest C# version (C# 12) and F# version (F# 8). It also includes built-in support for constructing container images directly from .NET projects. For Linux on Power (ppc64le) and IBM Z (s390x), the .NET 8 SDK now supports building self-contained applications. The base library, garbage collector (GC), and just-in-time compiler (JIT) have undergone numerous performance improvements.

For a comprehensive list of feature enhancements, refer to the Microsoft .NET 8 article.

How can I get .NET 8 for Linux on Power?

Fully supported Red Hat Package Manger (RPM) packages and container images, built from the open-source dotnet project, serve as the means for Red Hat customers to acquire .NET for the Power platform.

You can install .NET 8 on RHEL with the usual command:

dnf install dotnet-sdk-8.0

The .NET 8 SDK and runtime container images are available from the Red Hat Container Registry. You can use the container images as standalone images and with OpenShift on all supported architectures:

podman run ubi8 dnf install -y dotnet-sdk-8.0

Refer to the RHEL .NET 8 Documentation for detailed information, including ‘Getting Started with .NET 8’, ‘.NET 8 RPM Release Notes’, and ‘.NET 8 Container Release Notes’.

Use Case - Containerization of .NET applications on Power

Client challenges

As customers modernize their .NET applications, considering containerization with Red Hat OpenShift on Power is a viable option. Running front-end .NET applications (in a Linux partition) on the same physical server, hosting data on IBM i and AIX partitions has demonstrated an increase in the transactions per second rate.

Power and Openshift

Source: https://www.wwt.com/video/ibm-power10-with-red-hat-openshift

The .NET SDK container tooling offers an easy approach to build container images directly from a .NET project.

Following is a sample illustrating the process of creating a Linux on Power (ppc64le) container.

  1. Verify that you have .NET 8 installed
    
    # dotnet --info
    .NET SDK:
     Version:           8.0.100
     Commit:            57efcf1350
     Workload version:  8.0.100-manifests.2d90560f
    
    Runtime Environment:
     OS Name:     rhel
     OS Version:  8
     OS Platform: Linux
     RID:         rhel.8-ppc64le
     Base Path:   /usr/lib64/dotnet/sdk/8.0.100/
    
    .NET workloads installed:
     Workload version: 8.0.100-manifests.2d90560f
    There are no installed workloads to display.
    
    Host:
      Version:      8.0.0
      Architecture: ppc64le
      Commit:       5535e31a71
    
    .NET SDKs installed:
      8.0.100 [/usr/lib64/dotnet/sdk]
    
    .NET runtimes installed:
      Microsoft.AspNetCore.App 8.0.0 [/usr/lib64/dotnet/shared/Microsoft.AspNetCore.App]
      Microsoft.NETCore.App 8.0.0 [/usr/lib64/dotnet/shared/Microsoft.NETCore.App]
    
    Other architectures found:
      None
    
    Environment variables:
      Not set
    
    global.json file:
      Not found
    
    Learn more:
      https://aka.ms/dotnet/info
    
    Download .NET:
      https://aka.ms/dotnet/download
    
    
  2. Create a new project and move to its directory. Here ‘my-awesome-container-app’ is the project name.
    # create a new project and move to its directory
    dotnet new web -o my-awesome-container-app
    cd my-awesome-container-app
  3. Edit the ‘my-awesome-container-app.csproj’ file to set attributes for ContainerPublish.
    # Add attributes for container creation in my-awesome-container-app.csproj file
       <PropertyGroup>
        <ContainerRuntimeIdentifier>linux-ppc64le</ContainerRuntimeIdentifier>
        <ContainerBaseImage>registry.access.redhat.com/ubi8/dotnet-80-runtime:latest</ContainerBaseImage>
     </PropertyGroup>
    
    • For additional information on building containers, refer to the Tom Deseyn’s blog on building .NET 8
    • For additional information on ContainerBaseImage, refer to the Red Hat's .NET images (registry.access.redhat.com/ubi8/dotnet-80-runtime:latest) for ppc64le support on Linux, as the Microsoft's .NET images ( for example: ‘mcr.microsoft.com/dotnet/runtime:8.0’) lack support for ppc64le.
  4. Publish the .NET application.
    dotnet publish /p:PublishProfile=DefaultContainer
  5. Push the container image to an image registry or run locally on the machine where it was created.
    # podman images
    REPOSITORY                           TAG         IMAGE ID      CREATED         SIZE
    localhost/my-awesome-container-app   latest      ce7433753211  12 minutes ago  253 MB

    That’s all that is needed to create the Container image!

  6. Run the application image locally using Podman or Docker.
    podman run -p 8080:8080 my-awesome-container-app
  7. Visit the site on the exposed port for example by opening another terminal session of ppc64le machine and testing.
    curl localhost:8080

Customer references

Witness a case study where a customer seamlessly migrated their .NET application from Microsoft Azure to IBM Power Virtual Server featuring .NET 7. The customer successfully embraced the benefits of cloud-native development using Red Hat OpenShift on IBM’s Power cloud offering, IBM Power Virtual Server, for their .NET application in computer-aided design (CAD), computer-aided manufacturing (CAM), and computer-aided engineering (CAE) technologies.

Embrace the benefits of Red Hat OpenShift running on IBM Power Virtual Server.

  • Deploy and scale workloads globally.
  • Build cloud-native applications.
  • Get back time for core tasks.
  • Get more from software with less servers.
  • Modernize your applications.
  • Leverage open source to drive innovation.

Frequently asked questions

  1. Which IBM Platforms are released and maintained by Red Hat for .NET?
    • ppc64le (64-bit IBM Power) since .NET 7
    • s390x (64-bit IBM Z) since .NET 6
  2. How engaged is IBM/Red Hat with Microsoft on .NET?
    • .NET is an open-source project. IBM and Red Hat actively participate in the open-source community.
    • Regular conversations occur with Microsoft's development teams to address issues and enhance .NET for Linux, Z, and Power platforms.
  3. Does .NET on Linux (ppc64le/s390x) stay updated with .NET releases? What about support?
    • Red Hat collaborates closely with Microsoft to release and maintain .NET on Linux.
    • New versions and updates of .NET are released simultaneously with Microsoft as much as possible.
    • Bugfix/security updates are targeted within a week. New versions are generally available in a few weeks.
    • Red Hat and IBM collaborate with Microsoft to provide support for .NET, involving support and engineering teams as needed.
    • Architecture-specific issues on ppc64le/s390x platforms are automatically routed to the IBM team on behalf of the customer.
  4. When facing an issue with using .NET on IBM Power Platforms, what is the process to raise the issue?
    • The first step is gathering the specifics of the problem, along with a repeatable test case.
    • .NET support is included with RHEL and OpenShift subscriptions. Open a support case using the method mentioned in your support agreement.
    • Open a GitHub issue for community support.
    • For general issues,
      • Refer to the .NET blogs on the IBM Power Developer eXchange (PDeX) community to check if your question is answered.
      • Or post your question directly on the PDeX by starting a discussion thread on the ‘Programming Languages on Power’ group.
        Start new discussion thread
    • For application porting issues:

Conclusion

If your environment features IBM power machines, and you currently run .NET applications on other platforms, consider migrating these applications to Linux on Power. Evaluate whether this migration addresses challenges or frustrations, such as security, scalability, and latency.

In this blog, you learned about a use case with Containerization of .NET applications on IBM Power. What other use cases do you envision that leverage the capabilities of IBM Power machines?

We invite you to join the Power Developer eXchange community and drop your questions and comments. Your participation is highly valued as we collectively explore and unlock the full potential of IBM Power technologies.

References


#Featured-area-3
#Featured-area-3-home
#Featured-area-1
#Featured-area-1-home

Permalink