Dracut-initqueue swap does not exist during system boot

APPLIES TO

Operating System - Oracle Linux Server 7.4

SYMPTOMS

[198.935138] dracut-initqueue[310]: Warning: Could not boot.
[198.971675] dracut-initqueue[310]: Warning: /dev/ol/swap does not exist
Starting Dracut Emergency Shell...
Warning: /dev/ol/swap does not exist

CAUSE

The logical volume /dev/ol/swap was lost or not exist.

SOLUTION

  • Method 1
  1. Type blkid to list device information.

  2. Mount sysroot.

  3. Mount boot.

  4. Changing the default boot entry.

  5. Chanaging the the grub.cfg file.

    before

    after

  6. Reboot system.

    dracut:/# init 6

  • Method 2 (Recommended)
  1. Reboot system.

    dracut:/# init 6
  2. Press e to modify grub menu entries.

  3. Remove rd.lvm.lv=ol/swap parameter in the linux16 line

    before

    after

  4. Press Crtl-x to boot system.

  5. Make a backup for grub file.

    cp -a /etc/default/grub{,.bak}
    cp -a /boot/grub2/grub.cfg{,.bak}
  6. Changing the default boot entry, and rebuilding the grub.cfg file.

  7. Reboot system.

    systemctl reboot