Article 56EHF Trouble with new hardware, UEFI, grub and booting Debian10

Trouble with new hardware, UEFI, grub and booting Debian10

by
tredegar
from LinuxQuestions.org on (#56EHF)
I need some help please. The background:

My PC died. I had some backups.
I bought a Lenovo V530S. It came with windows10, so I let it boot to that.
As soon as I could, I shut down windows and fired up the UEFI interface (I am used to BIOS, but must march with the times.) The only thing I changed was the boot order, so it would boot from a DVD if one was present. I saved the changes and booted Debian 10 from a net-install CD.
I shrank the windows data partition to leave me a 180GB partition for Debian, and told the installer to put everything there, and not to touch the windows partitions. I don't want windows, but I've paid for it, and as I don't really understand this UEFI boot business, I am not sure how much of the SSD I can repartition and reformat.

Debian installed and installed grub. It did say that it could not find "any other operating systems, but if there was one (eg, windows,) that could be fixed later."

Debian 10 booted just fine, but at the grub menu I just have 2 entries Debian10 and Debian 10 safe mode, I think.

Today there was a new kernel installed. When it came to updating grub, there was an error message.
I can't remember exactly what it was (is it in a log somewhere?) it was to do with a grub problem, but I really don't want to power down this PC only to find it'll not boot Debian. I don't know how to fix a broken UEFI boot.

I thought I'd just run
Code:root@office:~# update-grub && grub-install /dev/sdabut before that, I thought I'd check the partitioning:
Code:root@office:~# fdisk -l
Disk /dev/nvme0n1: 238.5 GiB, 256060514304 bytes, 500118192 sectors
Disk model: SKHynix_HFS256GD9TNG-L5B0B
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: A25F9E0A-5749-40C9-A75A-95282CC249B4

Device Start End Sectors Size Type
/dev/ 2048 534527 532480 260M EFI System
/dev/nvme0n1p2 534528 567295 32768 16M Microsoft reserved
/dev/nvme0n1p3 567296 106036045 105468750 50.3G Microsoft basic data
/dev/nvme0n1p4 498069504 500107263 2037760 995M Windows recovery environment
/dev/nvme0n1p5 106037248 498069503 392032256 187G Linux filesystem

Partition table entries are not in disk order.And I am not a happy man!
Where is /dev/sda?
What is all this nvme0n1p* stuff? I know it relates to the type of SSD but has the naming of /dev/sd* gone the way of eth0 (which is now, so conveniently, enp0s25 )?

gdisk gives me this:
Code:root@office:~# gdisk -l
GPT fdisk (gdisk) version 1.0.3

Problem opening -l for reading! Error is 2.
The specified file does not exist!
root@office:~#gparted - please see the screenshot

What I would like to achieve is
- Install / troubleshoot grub
- Boot to the new kernel
- (Optionally, have the choice to boot win10)
- Not lose the EFI stuff (which is like a BIOS, but stored on the disk? How do I back this up in case the disk fails? Do I need to do this?)

Thanks for your attention.
Attached Thumbnailsattachment.php?attachmentid=33779&stc=1& latest?d=yIl2AUoC8zA latest?i=WzolQ9MzRUE:Z4i-zMmlq5A:F7zBnMy latest?i=WzolQ9MzRUE:Z4i-zMmlq5A:V_sGLiP latest?d=qj6IDK7rITs latest?i=WzolQ9MzRUE:Z4i-zMmlq5A:gIN9vFwWzolQ9MzRUE
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments