Arm processors are taking the cloud by storm. Developers are excited about this new technology’s impact on server workloads, and Oracle is committed to making their transition to Arm fast, easy, and free. Whether you’re moving existing workloads to Arm or building new ones on Arm, this post provides basic guidance for setting up your environment, deploying code, selecting workloads, getting help with optimization, and some best practices tips.
It’s time to set up your environment for Ampere A1 Compute. Most tools already support Arm, so you can use your favorite tools with no noticeable changes. If you want to quickly jumpstart your Linux environment for Arm, install the Oracle Linux Cloud Developer image. This image includes several language development and runtime environments with the OCI SDK for each.
To launch the Oracle Linux Cloud Developer image, log in to the OCI Console and navigate to the main menu under Compute, select Instance and Create Instance to configure the instance. Click Change Shape, select the Ampere VM.Standard.A1.Flex Compute shape, and configure the OCPU and memory for your instance. We recommend at least 8 GB of memory. Click Change Image and select the Oracle Linux Cloud Developer Image under Platform Images.
To view other examples of available developer tools, check out Oracle’s Works on Ampere A1 page, Ampere’s OCI Ampere A1 Solutions site, Works on Arm and the Arm Tools Repository. You can find more information for setting up your environment on Ampere’s developer page.
OCI uses the Ampere Altra Arm processor. This processor is optimized for running a diverse set of compute-intensive cloud applications. It’s well suited for containerized applications, continuous integration and deployment (CI/CD), Redis, memcached, MySQL, Nginx, machine learning inferencing, and media encoding. Instant Client support for Arm ensures that your applications can use Oracle Database.
We encourage developers working with Arm to take advantage of Kubernetes with Oracle Container Engine for Kubernetes (OKE) and build multi-arch images from a single source tree using Docker Buildx, Podman, or Buildah. Basically, you want to set up things so that one tag has images for both x86 and aarch64.
Although many applications work on our Ampere A1 Compute instances without code changes, some applications require platform-specific optimizations to achieve the best possible benefits from Arm. Check out Oracle’s Arm developer ecosystem to find information and help. Another resource available to share best practices and ask questions is the Stack Overflow community. Oracle watches the tags “oracle-cloud-infrastructure” and “arm.”
So, your code is running, but you want to tune it for even higher performance by taking advantage of the unique and more powerful capabilities of the Arm processor architecture. You can begin by baselining the code using third-party benchmarks or your own benchmarks. Many people like to use the Phoronix Test Suite. If you want to create custom benchmarks and need some help to get started, Java has a great primer.
The Ampere Altra processors in OCI are designed to run a single thread per core, have a lot of dedicated resources for each core, and have a lot of cores per socket. These processors also run consistently at the maximum clock frequency. These combined features allow you to achieve high performance by horizontally scaling Altra cores running single-threaded applications such as media encoding.
If you need more performance, for most server workloads you can add worker threads and cores to take advantage of the much lower cost per core that Ampere A1 Compute instances provide. This approach is ideally suited for the unlimited horizontal scaling that cloud computing enables.
Find more advanced tips regarding how to tune your application for best results on Ampere A1 shapes in this performance blog.
If you jumped to this section first in the blog, you won’t be disappointed. The following best practices and design principles are important for your applications running on Arm:
Update OS and language runtimes to the latest versions.
Update images or container registries, such as Arm64v8 repository on Docker Hub.
Update deployment scripts to ensure that they work for Arm deployments.
Tune low-level code, such as Arm GitHub repo for optimized routines
Test performance on multiple instance sizes.
Set up a CI/CD pipeline and use your automation to build for multiple platforms, such as Jenkins multi-arch pipeline.
Consider edge cases, such as high-latency responses.
Include Arm test cases in your test suite.
Get started with your Arm-based development project using Oracle Cloud Free Tier with Always Free Arm resources and $300 in free credits for 30 days. Oracle offers the most generous Always Free Arm resources in the industry with 4 OCPUs and 24-GB memory. If you need to run more Arm-based workloads and for a longer duration, apply for the Arm Accelerator and get more Oracle Cloud credits, valid for 365 days. After you get a free account, try the Ampere A1 Compute instances by deploying open source software like Nextcloud or set up a Kubernetes cluster using OKE.