Ohne EFI
sudo bash mount /dev/sda2 /mnt mount /dev/sda3 /mnt/boot mount -o bind /dev /mnt/dev mount -o bind /sys /mnt/sys mount -t proc /proc /mnt/proc chroot /mnt /bin/bash grub-install /dev/sda update-grub exit
Sollte der Fehler “Could not find device for /boot: Not found or not a block device.” auftreten, gibt man folgende Zeile vor dem grub-install ein:
cp /proc/mounts /etc/mtab
Mit EFI
sudo bash mount /dev/sda2 /mnt mount /dev/sda1 /boot/efi mount -o bind /dev /mnt/dev mount -o bind /sys /mnt/sys mount -t proc /proc /mnt/proc chroot /mnt /bin/bash grub-install /dev/sda update-grub exit
HP EliteBook G4
$ sudo parted -l Model: THNSN5512GPUK TOSHIBA (nvme) Disk /dev/nvme0n1: 512GB Sector size (logical/physical): 512B/512B Partition Table: gpt Disk Flags: Number Start End Size File system Name Flags 1 1049kB 379MB 377MB fat32 EFI system partition boot, esp 2 379MB 395MB 16.8MB Microsoft reserved partition msftres 3 395MB 325GB 325GB Basic data partition msftdata 4 325GB 495GB 170GB ext4 5 495GB 512GB 16.7GB linux-swap(v1) mount /dev/nvme0n1p4 /mnt mount /dev/nvme0n1p1 /mnt/boot/efi mount -o bind /dev /mnt/dev mount -o bind /sys /mnt/sys mount -t proc /proc /mnt/proc chroot /mnt /bin/bash grub-install /dev/nvme0n1 Installing for x86_64-efi platform. Installation finished. No error reported. update-grub2 Sourcing file `/etc/default/grub' Sourcing file `/etc/default/grub.d/50_linuxmint.cfg' Generating grub configuration file ... Found linux image: /boot/vmlinuz-4.15.0-54-generic Found initrd image: /boot/initrd.img-4.15.0-54-generic WARNING: Failed to connect to lvmetad. Falling back to device scanning. grub-probe: error: cannot find a GRUB drive for /dev/sda1. Check your device.map. Adding boot menu entry for EFI firmware configuration done <NO CHAIL> os-prober | tr ' ' '^' | paste -s -d ' ' </NO CHAIL> mv /etc/grub.d/30_os-prober /etc/grub.d/06_os-prober vi /etc/grub.d/06_os-prober #OSPROBED="`os-prober | tr ' ' '^' | paste -s -d ' '`" OSPROBED="/dev/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi:Windows^Boot^Manager:Windows:efi /dev/nvme0n1p4:Linux^Mint^19.2^Tina^(19.2):LinuxMint:linux" update-grub2 Sourcing file `/etc/default/grub' Sourcing file `/etc/default/grub.d/50_linuxmint.cfg' Generating grub configuration file ... Found Windows Boot Manager on /dev/nvme0n1p1@/EFI/Microsoft/Boot/bootmgfw.efi Found Linux Mint 19.2 Tina (19.2) on /dev/nvme0n1p4 Found linux image: /boot/vmlinuz-4.15.0-54-generic Found initrd image: /boot/initrd.img-4.15.0-54-generic Adding boot menu entry for EFI firmware configuration done # sudo efibootmgr -v BootCurrent: 000D Timeout: 0 seconds BootOrder: 0011,0013,000D,000A,0010,000E,000B,000C,0000,0001,0002,0003,0004,0005,0006,0007,0008,0009,000F Boot0000 Startup Menu FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)....ISPH Boot0001 System Information FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0002 Bios Setup FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0003 3rd Party Option ROM Management FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0004 System Diagnostics FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0005 System Diagnostics FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0006 System Diagnostics FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0007 System Diagnostics FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0008 Boot Menu FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0009 HP Recovery FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot000A* IPV4 Network - Intel(R) Ethernet Connection (4) I219-V PciRoot(0x0)/Pci(0x1f,0x6)/MAC(40b034e99e48,0)/IPv4(0.0.0.00.0.0.0,0,0)N.....YM....R,Y.....ISPH Boot000B* THNSN5512GPUK TOSHIBA-27BS1003T52T BBS(HD,THNSN5512GPUK TOSHIBA-27BS1003T52T,0x400)/PciRoot(0x0)/Pci(0x1d,0x0)/Pci(0x0,0x0)/NVMe(0x1,00-08-0D-02-00-1D-9C-DA)......ISPH Boot000C* Intel Corporation: IBA CL Slot 00FE v0110 BBS(Network,Intel Corporation: IBA CL Slot 00FE v0110,0x0)/PciRoot(0x0)/Pci(0x1f,0x6)/IPv4(0.0.0.00.0.0.0,0,0)......ISPH Boot000D* Verbatim STORE N GO 1242000000000826 PciRoot(0x0)/Pci(0x14,0x0)/USB(1,0)N.....YM....R,Y.....ISPH Boot000E USB: BBS(65535,,0x0)/PciRoot(0x0)/Pci(0x14,0x0)......ISPH Boot000F Network Boot FvVol(a881d567-6cb0-4eee-8435-2e72d33e45b5)/FvFile(9d8243e8-8381-453d-aceb-c350ee7757ca)......ISPH Boot0010* IPV6 Network - Intel(R) Ethernet Connection (4) I219-V PciRoot(0x0)/Pci(0x1f,0x6)/MAC(40b034e99e48,0)/IPv6([::]:<->[::]:,0,0)N.....YM....R,Y.....ISPH Boot0011* ubuntu HD(1,GPT,7f3b4501-d7e9-450e-b82a-5104c336081c,0x800,0xb4000)/File(\EFI\ubuntu\shimx64.efi) Boot0013* Windows Boot Manager HD(1,GPT,7f3b4501-d7e9-450e-b82a-5104c336081c,0x800,0xb4000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}...te...................ISPH # sudo efibootmgr -o 0011 BootCurrent: 000D Timeout: 0 seconds BootOrder: 0011 Boot0000 Startup Menu Boot0001 System Information Boot0002 Bios Setup Boot0003 3rd Party Option ROM Management Boot0004 System Diagnostics Boot0005 System Diagnostics Boot0006 System Diagnostics Boot0007 System Diagnostics Boot0008 Boot Menu Boot0009 HP Recovery Boot000A* IPV4 Network - Intel(R) Ethernet Connection (4) I219-V Boot000B* THNSN5512GPUK TOSHIBA-27BS1003T52T Boot000C* Intel Corporation: IBA CL Slot 00FE v0110 Boot000D* Verbatim STORE N GO 1242000000000826 Boot000E USB: Boot000F Network Boot Boot0010* IPV6 Network - Intel(R) Ethernet Connection (4) I219-V Boot0011* ubuntu Boot0013* Windows Boot Manager
# grub-install -v grub-install: info: executing modprobe efivars 2>/dev/null. grub-install: info: Looking for /sys/firmware/efi ... grub-install: info: ...found. Installing for x86_64-efi platform. grub-install: info: adding `hd0' -> `/dev/nvme0n1' from device.map. grub-install: info: /dev/nvme0n1p1 is present. grub-install: info: Looking for /dev/nvme0n1p1. grub-install: info: /dev/nvme0n1 is a parent of /dev/nvme0n1p1. grub-install: info: /dev/nvme0n1p1 starts from 2048. grub-install: info: opening the device hd0. [...] grub-install: info: scanning hd0 for LDM. grub-install: info: no LDM signature found. grub-install: info: Scanning for lvm devices on disk hd0. grub-install: info: no LVM signature found. grub-install: info: Partition 0 starts from 2048. grub-install: info: /dev/nvme0n1p1 is present. grub-install: info: Looking for /dev/nvme0n1p1. grub-install: info: /dev/nvme0n1 is a parent of /dev/nvme0n1p1. grub-install: info: /dev/nvme0n1p1 starts from 2048. grub-install: info: opening the device hd0. [...] grub-install: info: Partition 0 starts from 2048. grub-install: info: drive = 0. grub-install: info: the size of hd0 is 1000215216. grub-install: info: copying `/usr/lib/grub/x86_64-efi/net.mod' -> `/boot/grub/x86_64-efi/net.mod'. [...] grub-install: info: /dev/nvme0n1p4 is present. grub-install: info: Looking for /dev/nvme0n1p4. grub-install: info: /dev/nvme0n1 is a parent of /dev/nvme0n1p4. grub-install: info: /dev/nvme0n1p4 starts from 635619328. grub-install: info: opening the device hd0. [...] grub-install: info: Partition 0 starts from 2048. grub-install: info: grub-mkimage --directory '/usr/lib/grub/x86_64-efi' --prefix '/boot/grub' --output '/boot/grub/x86_64-efi/core.efi' --format 'x86_64-efi' --compression 'auto' --config '/boot/grub/x86_64-efi/load.cfg' 'ext2' 'part_gpt' 'search_fs_uuid' . grub-install: info: the size of config file is 0x68. grub-install: info: the total module size is 0x53e8. grub-install: info: reading /usr/lib/grub/x86_64-efi/kernel.img. [...] grub-install: info: Registering with EFI: distributor = `ubuntu', path = `\EFI\ubuntu\shimx64.efi', ESP at hd0,gpt1. grub-install: info: executing efibootmgr --version </dev/null >/dev/null. grub-install: info: executing modprobe -q efivars. grub-install: info: executing efibootmgr -b 0011 -B. [...] grub-install: info: executing efibootmgr -c -d /dev/nvme0n1 -p 1 -w -L ubuntu -l \EFI\ubuntu\shimx64.efi.
Boot-Repair
sudo add-apt-repository ppa:yannubuntu/boot-repair sudo apt-get update sudo apt-get install -y boot-repair && boot-repair
sudo chroot "/mnt/boot-sav/sda5" dpkg --configure -a sudo chroot "/mnt/boot-sav/sda5" apt-get install -fy sudo chroot "/mnt/boot-sav/sda5" apt-get purge -y --force-yes grub*-common grub-common:i386 shim-signed linux-signed* sudo chroot "/mnt/boot-sav/sda5" apt-get install -y --force-yes grub-pc linux-generic
Kernel Book Verbose
How do I enable verbose mode at boot?
How to enable boot messages to be printed on screen during boot up?
# If you change this file, run 'update-grub' afterwards to update # /boot/grub/grub.cfg. GRUB_CMDLINE_LINUX_DEFAULT="nosplash debug" GRUB_CMDLINE_LINUX=""
- Start your system and wait for the GRUB menu to show (if you don’t see a GRUB menu, press and hold the left Shift key right after starting the system).
- Now highlight the kernel you want to use, and press the e key. You should be able to see and edit the commands associated with the highlighted kernel.
- Go down to the line starting with linux and remove the parameters quiet and splash.
- Now press Ctrl + x to boot.