[Osaka/Yokohama/Tokushima] Looking for infrastructure/server side engineers!

[Osaka/Yokohama/Tokushima] Looking for infrastructure/server side engineers!

[Deployed by over 500 companies] AWS construction, operation, maintenance, and monitoring services

[Deployed by over 500 companies] AWS construction, operation, maintenance, and monitoring services

[Successor to CentOS] AlmaLinux OS server construction/migration service

[Successor to CentOS] AlmaLinux OS server construction/migration service

[For WordPress only] Cloud server “Web Speed”

[For WordPress only] Cloud server “Web Speed”

[Cheap] Website security automatic diagnosis “Quick Scanner”

[Cheap] Website security automatic diagnosis “Quick Scanner”

[Reservation system development] EDISONE customization development service

[Reservation system development] EDISONE customization development service

[Registration of 100 URLs is 0 yen] Website monitoring service “Appmill”

[Registration of 100 URLs is 0 yen] Website monitoring service “Appmill”

[Compatible with over 200 countries] Global eSIM “Beyond SIM”

[Compatible with over 200 countries] Global eSIM “Beyond SIM”

[If you are traveling, business trip, or stationed in China] Chinese SIM service “Choco SIM”

[If you are traveling, business trip, or stationed in China] Chinese SIM service “Choco SIM”

[Global exclusive service] Beyond's MSP in North America and China

[Global exclusive service] Beyond's MSP in North America and China

[YouTube] Beyond official channel “Biyomaru Channel”

[YouTube] Beyond official channel “Biyomaru Channel”

I want to use old repositories on Amazon Linux

AWS

This is Sashihara from the System Solutions Department.

For verification purposes, this is a memo from when I installed a slightly older version of the kernel on an Amazon Linux instance on AWS EC2.

overview

OS : Amazon Linux AMI release 2016.09

Old kernel : kernel-4.4.35-33.55.amzn1.x86_64

Kernel you want to put in : kernel-4.4.51-40.67.amzn1.x86_64

Trouble

I thought I could install it by specifying the version with yum install, but that didn't work.

[root@ip-xx-xx-xx-xx ~]# yum install kernel-4.4.51-40.67.amzn1.x86_64 Loaded plugins: priorities, update-motd, upgrade-helper No package kernel-4.4.51-40.67. amzn1.x86_64 available. Error: Nothing to do

The reason was that the corresponding package did not exist because I was referring to the latest version in Amazon's repository.

By the way, the latest kernel as of August 2, 2017 is 4.9.38-16.33.amzn1.x86_64.

How to deal with it

There is a setting item called releasever in the yum settings, which determines the repository to refer to.

The default is latest, so change that.

[root@ip-xx-xx-xx-xx ~]# vim /etc/yum.conf releasever=latest ↓ releasever=2016.09

 

Then execute yum, which failed earlier.

[root@ip-xx-xx-xx-xx ~]# yum install kernel-4.4.51-40.67.amzn1.x86_64 . . Installed: kernel.x86_64 0:4.4.51-40.67.amzn1 Complete!

 

After restarting the server, check the kernel information.

[root@ip-xx-xx-xx-xx ~]# uname -r 4.4.51-40.67.amzn1.x86_64

 

The specified kernel was installed without any problems.

By the way, the above method is also described in the AWS documentation

*For the listed responses, comment out the relevant line.

This gives you flexibility if you want to install an older version.

That's it.

If you found this article helpful , please give it a like!
0
Loading...
0 votes, average: 0.00 / 10
3,493
X facebook Hatena Bookmark pocket
[2025.6.30 Amazon Linux 2 support ended] Amazon Linux server migration solution

[2025.6.30 Amazon Linux 2 support ended] Amazon Linux server migration solution

The person who wrote this article

About the author