Grub2 Password: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
| (11 dazwischenliegende Versionen von 2 Benutzern werden nicht angezeigt) | |||
| Zeile 1: | Zeile 1: | ||
| + | [[Kategorie:GRUB]] | ||
=Wir erstellen ein Passwort= | =Wir erstellen ein Passwort= | ||
| − | *grub- | + | *grub-mkpasswd-pbkdf2 |
| + | oder | ||
| + | *grub2-mkpasswd-pbkdf2 | ||
| + | PBKDF2-Prüfsumme Ihres Passworts ist grub.pbkdf2.sha512.10000.8F6C7937907C2E11F5CA1B141538E6D268C697... | ||
| + | <!-- PBKDF2-Prüfsumme Ihres Passworts ist grub.pbkdf2.sha512.10000.8F6C7937907C2E11F5CA1B141538E6D268C6975B54228042D71B749BC4A94959F5744009AF1111FC3FE753D1E12C572B70157A0A5B80F7C229A0EFE7909DC9A3.6CD5B1ACB8B0DD8AAE1CB1705814F92F59A0C4F9C7E692F309B861F2C1935D354BEBC1F889EA749F016056BDC20E165727DE73EB4DA9CD5210790A4D9823AC31 --> | ||
| + | |||
=Danach wird dies an die Datei /etc/grub.d/40_custom gehängt= | =Danach wird dies an die Datei /etc/grub.d/40_custom gehängt= | ||
;Der Schlüssel wurde hier zur besseren Darstellung gekürzt. | ;Der Schlüssel wurde hier zur besseren Darstellung gekürzt. | ||
| Zeile 8: | Zeile 14: | ||
# menu entries you want to add after this comment. Be careful not to change | # menu entries you want to add after this comment. Be careful not to change | ||
# the 'exec tail' line above. | # the 'exec tail' line above. | ||
| − | set superusers= | + | set superusers="admin" |
| − | password_pbkdf2 | + | password_pbkdf2 admin grub.pbkdf2.sha512.10000.CB7420E44ED9D672920C79794FD81352B0623BB7 |
| + | |||
=Abschluss= | =Abschluss= | ||
;update-grub baut anhand der Skripte unter /etc/grub.d eine neue /etc/grub/grub.conf | ;update-grub baut anhand der Skripte unter /etc/grub.d eine neue /etc/grub/grub.conf | ||
*update-grub | *update-grub | ||
| + | |||
| + | bzw. | ||
| + | |||
| + | *grub-mkconfig -o /boot/grub/grub.cfg | ||
;Der jetztige Zustand erlaubt nur ein Booten wenn man das Passwort eingibt | ;Der jetztige Zustand erlaubt nur ein Booten wenn man das Passwort eingibt | ||
| − | =Automatisches Booten aber kein Ändern der Booting Einträge | + | |
| − | + | =Automatisches Booten, aber kein Ändern der Booting Einträge= | |
| − | *sed -i.bak "s/--class os/& --unrestricted/" /etc/grub.d/10_linux | + | *'''sed -i.bak "s/--class os/& --unrestricted/" /etc/grub.d/10_linux''' |
| − | *rm /etc/grub.d/10_linux.bak | + | *'''rm /etc/grub.d/10_linux.bak''' |
| − | + | *Abschliessend wieder eine | |
| − | *update-grub | + | *'''update-grub''' |
| + | =Redhat= | ||
| + | *grub2-setpassword | ||
Aktuelle Version vom 16. September 2024, 20:16 Uhr
Wir erstellen ein Passwort
- grub-mkpasswd-pbkdf2
oder
- grub2-mkpasswd-pbkdf2
PBKDF2-Prüfsumme Ihres Passworts ist grub.pbkdf2.sha512.10000.8F6C7937907C2E11F5CA1B141538E6D268C697...
Danach wird dies an die Datei /etc/grub.d/40_custom gehängt
- Der Schlüssel wurde hier zur besseren Darstellung gekürzt.
#!/bin/sh exec tail -n +3 $0 # This file provides an easy way to add custom menu entries. Simply type the # menu entries you want to add after this comment. Be careful not to change # the 'exec tail' line above. set superusers="admin" password_pbkdf2 admin grub.pbkdf2.sha512.10000.CB7420E44ED9D672920C79794FD81352B0623BB7
Abschluss
- update-grub baut anhand der Skripte unter /etc/grub.d eine neue /etc/grub/grub.conf
- update-grub
bzw.
- grub-mkconfig -o /boot/grub/grub.cfg
- Der jetztige Zustand erlaubt nur ein Booten wenn man das Passwort eingibt
Automatisches Booten, aber kein Ändern der Booting Einträge
- sed -i.bak "s/--class os/& --unrestricted/" /etc/grub.d/10_linux
- rm /etc/grub.d/10_linux.bak
- Abschliessend wieder eine
- update-grub
Redhat
- grub2-setpassword