This repository has been archived on 2020-11-27. You can view files and clone it, but cannot push or open issues or pull requests.
readme/grubshell.md

26 lines
871 B
Markdown
Raw Normal View History

2019-04-09 12:33:53 +00:00
## booter depuis le shell grub
- les commande **cat** et **ls** fonctionne
- trouver partition de boot
- mettre la partion en racine `set root=(hd0,1)`
- charger le kernel ce trouvant sur cette partition et setter la partition racine: `linux /vmlinuz root=/dev/sda3`
- charger le fichier image correspondant au kernel :`initrd /boot/initrd.img`
- enter `boot` to boot
2019-04-09 12:47:13 +00:00
## regénérer config
`grub-mkconfig -o /boot/grub/grub.cfg`
2019-04-09 12:33:53 +00:00
2019-04-09 12:47:13 +00:00
## install sur MBR
`grub-install --target=i386-pc /dev/sdX`
2019-04-09 12:33:53 +00:00
## meme chose depuis grub rescue
`grub rescue> set prefix=(hd0,1)/boot/grub
grub rescue> set root=(hd0,1)
grub rescue> insmod normal
grub rescue> normal
grub rescue> insmod linux
grub rescue> linux /boot/vmlinuz-3.13.0-29-generic root=/dev/sda1
grub rescue> initrd /boot/initrd.img-3.13.0-29-generic
2019-04-09 12:47:13 +00:00
grub rescue> boot`
[archwiki](https://wiki.archlinux.org/index.php/GRUB)