]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
test kernel-test
authorPatrick Donnelly <pdonnell@redhat.com>
Tue, 3 Mar 2026 02:33:23 +0000 (21:33 -0500)
committerPatrick Donnelly <pdonnell@redhat.com>
Tue, 3 Mar 2026 14:01:31 +0000 (09:01 -0500)
teuthology/task/kernel.py

index a96f2ce8070f83f02b7418dbb2038e7297acd4dc..2768afb14ae81648e128c9b40b5014b81e21057a 100644 (file)
@@ -598,6 +598,10 @@ def install_and_reboot(ctx, need_install, config):
                 '--',
                 '/etc/grub.d/01_ceph_kernel.tmp~',
                 '/etc/grub.d/01_ceph_kernel',
+                run.Raw('&&'),
+                'sudo', 'sed', '-i',
+                '/^GRUB_CMDLINE_LINUX_DEFAULT=/ {/reboot=pci/! s/"$/ reboot=pci,force"/}',
+                '/etc/default/grub',
                 # update grub again so it accepts our default
                 run.Raw('&&'),
                 'sudo',
@@ -863,6 +867,11 @@ def install_kernel(remote, role_config, path=None, version=None):
             teuthology.delete_file(remote, '/etc/grub.d/01_ceph_kernel', sudo=True, force=True)
             teuthology.sudo_write_file(remote, '/etc/grub.d/01_ceph_kernel', StringIO(grubfile), '755')
             log.info('Distro Kernel Version: {version}'.format(version=newversion))
+            remote.run(args=[
+                'sudo', 'sed', '-i',
+                '/^GRUB_CMDLINE_LINUX_DEFAULT=/ {/reboot=pci/! s/"$/ reboot=pci,force"/}',
+                '/etc/default/grub'
+            ])
             remote.run(args=['sudo', 'update-grub'])
             remote.safe_hard_reboot()
             return
@@ -1044,6 +1053,12 @@ def grub2_kernel_select_generic(remote, newversion, ostype):
     else:
         raise UnsupportedPackageTypeError(f"Unknown ostype: {ostype}")
 
+    remote.run(args=[
+        'sudo', 'sed', '-i',
+        '/^GRUB_CMDLINE_LINUX_DEFAULT=/ {/reboot=pci/! s/"$/ reboot=pci,force"/}',
+        '/etc/default/grub'
+    ])
+
     if _kernel_has_bls(remote):
         status_ok = _kernel_set_default_bls(remote, newversion, ostype)
         if not status_ok: