CentOS 7系统安装Kernel 3.19版本的方法咨询
Got it, the issue here is that the current ElRepo repositories don't host Kernel 3.19 anymore—it’s too old, so it won’t show up in yum list results. Let’s walk through how to install it manually:
Step 1: Check your system architecture
First, confirm you’re running a 64-bit system (standard for CentOS 7):
uname -m
You should see x86_64 as the output.
Step 2: Import the ElRepo GPG key
This ensures you can trust the authenticity of the old kernel packages:
sudo rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
Step 3: Download the Kernel 3.19 RPM package
You’ll need to find the correct Kernel 3.19 RPM built for CentOS 7 x86_64. Look for packages named kernel-3.19.*.el7.x86_64.rpm from archived ElRepo sources. Once you have the package, download it to your system (use wget if you have the direct link):
sudo wget <path-to-your-kernel-3.19-rpm-file>
Step 4: Install the kernel package
Use rpm to install the downloaded package:
sudo rpm -ivh kernel-3.19*.rpm
The -ivh flag gives you verbose output and a progress hash so you can track the installation.
Step 5: Set Kernel 3.19 as the default boot option
After installation, your system will still boot into the original 3.10 kernel by default. Let’s fix that:
- List all available kernel entries in GRUB to find the index for 3.19:
sudo awk -F\' '$1=="menuentry " {print i++ " : " $2}' /etc/grub2.cfg - Note the number next to the Kernel 3.19 entry (it’s usually the first or second one).
- Set that index as the default boot option:
sudo grub2-set-default <index-number> - Regenerate the GRUB configuration to apply the change:
sudo grub2-mkconfig -o /boot/grub2/grub.cfg
Step 6: Reboot and verify
Restart your system to load the new kernel:
sudo reboot
Once you’re logged back in, confirm the kernel version with:
uname -r
You should see 3.19.* as the output if everything worked.
内容的提问来源于stack exchange,提问作者olimp olimp

