Hier werden die Unterschiede zwischen zwei Versionen gezeigt.
Nächste Überarbeitung | Vorherige Überarbeitung | ||
lpi1:bootloader [2011/10/26 08:47] 127.0.0.1 Externe Bearbeitung |
lpi1:bootloader [2020/01/29 13:08] |
||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
- | ====== Bootloader ====== | ||
- | ===== Bootloader löschen ===== | ||
- | dd if=/dev/zero of=/dev/sda bs=446 count=1 | ||
- | ===== grub ===== | ||
- | ==== Grub installieren ==== | ||
- | === Debian === | ||
- | apt-get install grub | ||
- | grub-install /dev/sda | ||
- | oder | ||
- | grub | ||
- | root (hd0,0) | ||
- | setup (hd0) | ||
- | quit | ||
- | |||
- | update-grub | ||
- | |||
- | === SuSE === | ||
- | grub-install /dev/sda | ||
- | oder | ||
- | grub | ||
- | root (hd0,0) | ||
- | setup (hd0) | ||
- | quit | ||
- | |||
- | ==== Neuen Kernel testen ==== | ||
- | System rebooten, und einmalig den 3. Eintrag ( grub fängt bei 0 an zu zählen ... ) aus ''/boot/grub/menu.lst'' verwenden: | ||
- | |||
- | SuSE: | ||
- | grubonce 2 | ||
- | |||
- | Debian: | ||
- | grub-reboot 2 | ||
- | |||
- | ==== Grub mit Passwort absichern ==== | ||
- | === Root Passwort ändern === | ||
- | Grub Bootprompt: ''init=/bin/bash'' hinzufügen | ||
- | |||
- | Kernel mit ''b'' booten | ||
- | |||
- | mount -o remount,rw / | ||
- | passwd | ||
- | mount -o remount,ro / | ||
- | exec /sbin/init | ||
- | |||
- | === Grub absichern === | ||
- | /usr/sbin/grub-md5-crypt | ||
- | |||
- | ''/boot/grub/menu.lst'' : | ||
- | <file> | ||
- | password --md5 $1$ZkniA/$2EBU5eSONAj.i2KIhhtWA0 | ||
- | </file> | ||
- | |||
- | ===== grub2 ===== | ||
- | ==== Grub installieren ==== | ||
- | === Debian 6.0 === | ||
- | apt-get install grub-pc | ||
- | update-grub2 | ||
- | |||
- | ==== Grub2 mit Passwort absichern ==== | ||
- | Debian 6.0 | ||
- | |||
- | === Root Passwort ändern === | ||
- | Grub Bootprompt: ''init=/bin/bash'' hinzufügen | ||
- | |||
- | Kernel mit ''strg+x'' booten | ||
- | |||
- | mount -o remount,rw / | ||
- | passwd | ||
- | mount -o remount,ro / | ||
- | exec /sbin/init | ||
- | |||
- | === Grub absichern === | ||
- | grub-mkpasswd-pbkdf2 | ||
- | |||
- | ''/etc/grub.d/45_password'' : | ||
- | <file> | ||
- | #!/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="root" | ||
- | password_pbkdf2 root grub.pbkdf2.sha512.10000.FF73A777C6793E117430446F4D12F00D25DA53515B5048B1DAAA0688743550226CD05AD661EBDCA2AA1997AEBDC0C35C74CA48C9309FBED1C201C5875E3AD2E8.292A1642CB109860054562756A5AE950975B586A8DFDE535F566D1ADDCC6747349406E84862FFD9258F64268A36E63EF25A41A3CC0CD6291E63D98CEDDF00FE6 | ||
- | </file> | ||
- | |||
- | chmod +x /etc/grub.d/45_password | ||
- | update-grub | ||
- | == testen == | ||
- | grep password /boot/grub/grub.cfg | ||
- | reboot | ||
- | | ||
- | ===== Dokus & Links ===== | ||
- | * http://wiki.ubuntuusers.de/grub_2/konfiguration |