選取您的 Cookie 偏好設定

我們使用提供自身網站和服務所需的基本 Cookie 和類似工具。我們使用效能 Cookie 收集匿名統計資料,以便了解客戶如何使用我們的網站並進行改進。基本 Cookie 無法停用,但可以按一下「自訂」或「拒絕」以拒絕效能 Cookie。

如果您同意,AWS 與經核准的第三方也會使用 Cookie 提供實用的網站功能、記住您的偏好設定,並顯示相關內容,包括相關廣告。若要接受或拒絕所有非必要 Cookie,請按一下「接受」或「拒絕」。若要進行更詳細的選擇,請按一下「自訂」。

Using AL1 on AWS

焦點模式
Using AL1 on AWS - Amazon Linux 1
此頁面尚未翻譯為您的語言。 請求翻譯
Warning

Amazon Linux 1 (AL1, formerly Amazon Linux AMI) is no longer supported. This guide is available only for reference purposes.

Note

AL1 is no longer the current version of Amazon Linux. AL2023 is the successor to AL1 and AL2. For more information about what's new in AL2023, see Comparing AL1 and AL2023 section in the AL2023 User Guide and the list of Package changes in AL2023.

Because AL1, is now EOL, support for newer instance types and AWS Regions will not be added.

Repository configuration

For AL1 and AL2, AMIs are a snapshot of the packages available at the time the AMI was created, with the exception of security updates. Any packages not on the original AMI, but installed at run time, will be the latest version available. To get the latest packages available for AL1, run yum update -y.

For AL2023, the repository configuration has changed compared to AL1 and AL2. For more information about the AL2023 repository, see Managing packages and operating system updates.

Versions up to AL2023 were configured to deliver a continuous flow of updates to roll from one minor version of Amazon Linux to the next version, also called rolling releases. As a best practice, we recommend you update your AMI to the latest available AMI. Don't launch Amazon Linux AMIs that use an older version.

In-place upgrades are not supported between major Amazon Linux versions, such as from AL1 to AL2 or from AL2 to AL2023. For more information, see Amazon Linux availability.

Using lock-on-launch in Amazon Linux

You can disable rolling releases by enabling the lock-on-launch feature. The lock-on-launch feature locks your instance to receive updates only from the specified release of the AMI

For example, you can launch a 2017.09 AMI and have it receive only the updates that were released prior to the 2018.03 AMI, until you are ready to migrate to the 2018.03 AMI.

Important

If you enable the lock-on-launch feature and choose a version of the repositories that is not the latest, you don't receive further updates. To receive rolling releases, you must use the latest AMI, or consistently update your AMI with the repositories pointed to latest.

To enable the lock-on-launch feature in new instances, launch it with the following user data passed to cloud-init:

#cloud-config repo_releasever: 2017.09
To lock existing instances to their current AMI version
  1. Edit /etc/yum.conf.

  2. Comment out releasever=latest.

  3. To clear the cache, run yum clean all.

在本頁面

隱私權網站條款Cookie 偏好設定
© 2025, Amazon Web Services, Inc.或其附屬公司。保留所有權利。