Zum Inhalt

Quick Tip: How to rebuild all initrds with dracut in CentOS 6/7

If you need to automatically rebuild all initrds for all installed kernels:

rpm -qa | grep kernel | grep -v headers | grep -v tools | sed 's/^kernel\-//g' | xargs -i dracut -v -f /boot/initramfs-{}.img {}

Oh, and while we're at it, the same for Ubuntu

update-initramfs -u -k all

Published inTechTalk

3 Comments

  1. Anonymous Anonymous

    It's this now:

    dracut –regenerate-all -v -f

  2. Anonymous Anonymous

    dracut –regenerate-all -v -f

    to be quite correct 😉

  3. Anonymous Anonymous

    Ah, I see what's happening. Make that two dashes in front of regenerate:

    dracut – -regenerate-all -v -f

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht.

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.