Symptom
During OS migration, the error "Newest installed kernel not in use" is reported.
Cause
The latest installed kernel is not set as the default boot kernel on the source server, which may cause the migration to fail.
Solution
Set the latest kernel as the default boot kernel, restart the server, and run the migration again.
-
Connect to the ECS instance to migrate. Connect to a Linux instance by using a password or key.
-
Run the following command to list all installed kernels:
cat /boot/grub2/grub.cfg | grep menuentrySample output. Each kernel name is enclosed in single quotation marks (').
if [ x"${feature_menuentry_id}" = xy ]; then menuentry_id_option="--id" menuentry_id_option="" export menuentry_id_option menuentry 'CentOS Linux (3.10.0-229.14.1.el7.x86_64) 7 (Core)' --class centos --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.10.0-123.el7.x86_64-advanced-6634633e-001d-43ba-8fab-202f1df93339' { } menuentry 'CentOS Linux (3.10.0-123.9.3.el7.x86_64) 7 (Core)' --class centos --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.10.0-123.el7.x86_64-advanced-6634633e-001d-43ba-8fab-202f1df93339' { } menuentry 'CentOS Linux, with Linux 0-rescue-45461f76679f48ee96e95da6cc798cc8' --class centos --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-0-rescue-45461f76679f48ee96e95da6cc798cc8-advanced-6634633e-001d-43ba-8fab-202f1df93339' { } -
Set the latest kernel as the default boot kernel.
Example: if the latest kernel is CentOS Linux (3.10.0-229.14.1.el7.x86_64) 7 (Core), run:
grub2-set-default 'CentOS Linux (3.10.0-229.14.1.el7.x86_64) 7 (Core)' -
Verify the configuration:
grub2-editenv listExpected output:
[root@iZbp1iufd7vqhweezkx**** ~]# grub2-editenv list saved_entry=CentOS Linux (3.10.0-229.14.1.el7.x86_64) 7 (Core) -
Restart the ECS instance to boot with the new kernel.
-
After you resolve the network issue, run the SMC client to retry the operation. For more information, see Run the SMC client.