×
Community Blog Exploring Aliyun Linux – A Linux Distro Made in the Cloud for the Cloud

Exploring Aliyun Linux – A Linux Distro Made in the Cloud for the Cloud

In this article, we'll take a closer look at Aliyun Linux and will discuss the advantages of using it over other Linux-based distribution.

By Alberto Roura, Alibaba Cloud Community Blog Author.

In this article I'll go through the advantages of using Aliyun Linux, a CentOS-based Linux distribution developed and maintained by Alibaba Cloud. Compared to other available Virtual Machine images like Debian/Ubuntu or RHEL/CentOS (amongst others), Aliyun Linux is made in the cloud and for the cloud.

 
Aliyun Linux

 
Alibaba optimised this distribution to the point that, if your application is going to run on an Alibaba Cloud ECS, makes a lot of sense to use it. Some of the optimisations are:

  • Faster system startups.
  • Better runtime performance.
  • Less potential security risks.
  • Capability of enable/disable kdump without rebooting the VM.
  • Kernel Live Patching.
  • Built-In Alibaba Cloud CLI.
  • Optimized multi-threaded performance for high-spec ECS instance types.
  • Optimized for MySQL scenarios.
  • Several updates on kernel parameters to increase reliability.

 

Quick Start with Aliyun Linux

This article assumes that you already have an Alibaba Cloud account. Click here to create one if you don't have one. For this example, I'll be using the web console to create an ECS instance with the latest version of Aliyun Linux 2, if you want to deploy it using Terraform, check out my blog, Deploying and Best Practices with Alibaba Cloud, to get an idea of how to start.

To keep things easy, let's create the ECS Instance by using the Quick Launch mode, a very neat and tidy interface to quickly create an instance with the most common options used. If you need more control you can click on the "Custom Launch" tab.

Whichever option you choose, the only difference compared to launching other Operating Systems is in the "Image" part, where you should choose "Aliyun Linux" from the list or dropdown.

Remember that, if you want to create the instance just to play a bit, select "Pay-As-You-Go", otherwise just go with a "Subscription" mode where you can save some money over time. If everything looks right, click "Create Instance" in the last step and in around 1 minute or less, your Aliyun Linux-powered ECS will be ready to accept SSH connections.

 
Screen_Shot_2019_12_05_at_11_29_18_am
The new ECS showing off the shiny Alibaba Cloud logo
 

Scenarios where Aliyun Linux stands out

We can keep talking about the technical advantages of Aliyun Linux forever, but without real-world scenarios to showcase, this would be empty. Let's have a look to the best and most popular use-cases.

 

Using with ECS Instance RAM Roles

Forget about writing API keys and secrets to environment variables, since this Linux distribution comes with aliyun-cli, all API calls will take advantage of the RAM role applied to the Virtual Machine itself. This makes your application deployment way safer, manageable and predictable. You can do things like:

All of the above without using credentials explicitly, quite cool if you ask me. Just make sure your RAM Role has a Policy granting access to those resources, of course!

 

Running Heavy and Problematic Workloads

If you are developing a very experimental piece of software and you expect the binary to crash, freeze or behave weirdly very often, you can enable, at any time and no rebooting, kdump and check what is going on. kdump is a feature of the Linux kernel itself that creates crash dumps in the event of a kernel crash.

For this to work, just run systemctl enable kdump.service && systemctl restart kdump.service and the next crash will be logged. To disable it, run systemctl disable kdump.service && systemctl stop kdump.service.

 

Using the ECS to Host Both an Application and a Database

I still recommend you to use RDS to run databases, as it brings down the maintenance requirements from your side. It automates backups, replications with a few clicks and they run always in a very optimized environment. But if for business or technical requirements, you need a custom-made MySQL, NoSQL server or real-time analysis applications, Aliyun Linux has your back. If you connect an ESSD to the instance, you can expect a very high performance. ESSDs (Enhanced SSDs) are currently based on a 25GE network and RDMA (Remote Direct Memory Access) technology. This technology comes perfect when short latency and high throughput are required, like OLTP and other file-intensive scenarios.

 

Better Scalability

As Aliyun Linux is optimized to be used on ECS instances, all operations involving instance creation, reboots and startups will happen faster and your application will scale more precisely. Personally, I find the time from launching an instance for it to be fully operative (I can see system logs) incredibly fast compared to other images, including Linux images running on other cloud service providers.

Think about scenarios where you have some auto-scaling rules to get triggered when certain metrics are on the limit. With faster startup times, your Load Balancers will get backends ready to get used in a much shorter time.

 

Conclusion

As you can see, even for a Debian fan like myself, Aliyun Linux comes as a natural selection when using Alibaba Cloud ECS instances. There is way less overhead when setting up my projects and using ECS in combination with other resources.

Give it a try and thank you for reading!

0 0 0
Share on

rouralberto

8 posts | 4 followers

You may also like

Comments

rouralberto

8 posts | 4 followers

Related Products

  • Alibaba Cloud Linux

    Alibaba Cloud Linux is a free-to-use, native operating system that provides a stable, reliable, and high-performance environment for your applications.

    Learn More
  • Red Hat Enterprise Linux

    Take advantage of the cost effectiveness, scalability, and flexibility of Alibaba Cloud's infrastructure and services, as well as the proven reliability of Red Hat Enterprise Linux and Alibaba Cloud's support backed by Red Hat Global Support Services.

    Learn More
  • Function Compute

    Alibaba Cloud Function Compute is a fully-managed event-driven compute service. It allows you to focus on writing and uploading code without the need to manage infrastructure such as servers.

    Learn More
  • Cloud Migration Solution

    Secure and easy solutions for moving you workloads to the cloud

    Learn More