→ kernel 戻そう
→ grubby!!!
現状を確認する
$ uname -a
Linux e130 5.8.4-200.fc32.x86_64 #1 SMP Wed Aug 26 22:28:08 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
$ sudo grubby --default-kernel
/boot/vmlinuz-5.8.4-200.fc32.x86_64
grub2のメニューを見る
$ sudo grubby --info=ALL
index=0
kernel="/boot/vmlinuz-5.8.4-200.fc32.x86_64"
args="ro resume=/dev/mapper/fedora_localhost--live-swap rd.lvm.lv=fedora_localhost-live/root rd.lvm.lv=fedora_localhost-live/swap rhgb quiet systemd.unified_cgroup_hierarchy=0"
root="/dev/mapper/fedora_localhost--live-root"
initrd="/boot/initramfs-5.8.4-200.fc32.x86_64.img"
title="Fedora (5.8.4-200.fc32.x86_64) 32 (Thirty Two)"
id="429fc1c27543423bb074b9349983b086-5.8.4-200.fc32.x86_64"
index=1
kernel="/boot/vmlinuz-5.7.15-200.fc32.x86_64"
args="ro resume=/dev/mapper/fedora_localhost--live-swap rd.lvm.lv=fedora_localhost-live/root rd.lvm.lv=fedora_localhost-live/swap rhgb quiet systemd.unified_cgroup_hierarchy=0"
root="/dev/mapper/fedora_localhost--live-root"
initrd="/boot/initramfs-5.7.15-200.fc32.x86_64.img"
title="Fedora (5.7.15-200.fc32.x86_64) 32 (Thirty Two)"
id="429fc1c27543423bb074b9349983b086-5.7.15-200.fc32.x86_64"
index=2
kernel="/boot/vmlinuz-5.7.11-200.fc32.x86_64"
(以下略)
デフォルトを変更する
--set-default=kernel-path make the first entry referencing the specified kernel the default --set-default-index=entry-index make the given entry index the default entry
とあるので、どちらかのコマンドを入れる
# メニューインデックス指定の場合
$ sudo grubby --set-default-index=1
The default is /boot/loader/entries/429fc1c27543423bb074b9349983b086-5.7.15-200.fc32.x86_64.conf with index 1 and kernel /boot/vmlinuz-5.7.15-200.fc32.x86_64
# カーネルイメージ指定の場合
$ sudo brubby --set-default=/boot/vmlinuz-5.7.15-200.fc32.x86_64
(略)
本当に変更されたか確認
$ sudo grubby --default-kernel
/boot/vmlinuz-5.7.15-200.fc32.x86_64
リブートし、カーネル確認
$ sudo reboot
Connection to 192.168.10.151 closed by remote host.
Connection to 192.168.10.151 closed.
# 待つ・・・
$ ssh e130
Last login: Fri Sep 4 14:13:23 2020 from 192.168.10.123
# カーネルバージョン確認
$ uname -a
Linux e130 5.7.15-200.fc32.x86_64 #1 SMP Tue Aug 11 16:36:14 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux