Solved Grub

Solved issue

Madd00x

New Member
Joined
Jun 25, 2023
Messages
17
Reaction score
3
Credits
221
Hello, after the upgrade Grub was not installed due to lack of space. I removed some MB from /boot/efi and added them to /boot.
How do I rewrite Grub from live USB?
Code:
fdisk -l
Disk /dev/nvme1n1: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: SPCC M.2 PCIe SSD
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: 89C656F8-6AC0-3A42-AC10-B627FF11EF2E
Device Start End Sectors Size Type
/dev/nvme1n1p1 2048 411647 409600 200M EFI System
/dev/nvme1n1p2 1953792 1953523711 1951569920 930.6G Linux filesystem
/dev/nvme1n1p3 411648 1953791 1542144 753M Linux filesystem


Code:
lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
loop0 7:0 0 2.7G 1 loop /usr/lib/live/mount/rootfs/filesystem.squashfs
/run/live/rootfs/filesystem.squashfs
sda 8:0 1 59.8G 0 disk
├─sda1 8:1 1 3.2G 0 part /usr/lib/live/mount/medium
│ /run/live/medium
└─sda2 8:2 1 5M 0 part
nvme1n1 259:0 0 931.5G 0 disk
├─nvme1n1p1 259:1 0 200M 0 part
├─nvme1n1p2 259:2 0 930.6G 0 part
└─nvme1n1p3 259:3 0 753M 0 part
nvme0n1 259:4 0 465.8G 0 disk
├─nvme0n1p1 259:5 0 1G 0 part
├─nvme0n1p2 259:6 0 300M 0 part
└─nvme0n1p3 259:7 0 440G 0 part
 


Hi, do you have other OS's on your disk ex. Windows or only this 1 Linux?

Grub should be installed to /dev/nvme1n1p1 which is EFI partition.
 
the upgrade Grub was not installed due to lack of space.
Was this install partitioned manually or were the partitions taken care of by the installer ?
/dev/nvme1n1p1 2048 411647 409600 200M EFI System
....??....I am seeing 200M....is this disc lvm partitioned?....encrypted?.....is there a chance there is another OS on the disk...eg windows and you have installed part of lInux to a windows file system ?
 
And what is your 2nd disk nvme0n1? data drive?

If you're doing this from live USB you need to have Boot partition mounted to /boot and EFI partition mounted to /boot/efi
If these partitions are mounted to these mount points then it's as simple as running grub-install as root or sudo.

See here:

That's what I would do, I've never had to do it by hand though so maybe wait until someone confirms this.
 
And what is your 2nd disk nvme0n1? data drive?

If you're doing this from live USB you need to have Boot partition mounted to /boot and EFI partition mounted to /boot/efi
If these partitions are mounted to these mount points then it's as simple as running grub-install as root or sudo.

See here:

That's what I would do, I've never had to do it by hand though so maybe wait until someone confirms this.
YES, the initial setup was having /boot and /boot/efi, but as i wrote i got low space in the boot partition then i resized moving from efi to boot.
I need step by step how to do
"And what is your 2nd disk nvme0n1? data drive?"
I have installed Fedora.
;)
 
YES, the initial setup was having /boot and /boot/efi, but as i wrote i got low space in the boot partition then i resized moving from efi to boot.
I need step by step how to do ;)
I think it's wrong to move from EFI to Boot because those moved files will be useless, if there is not enough space on EFI then partition should be resized, and this mean reformatting, creating new partition layout and system reinstall.

If you're installing new system then there is nothing to lose to reformat and grub should install without hackery during install.
 
I think it's wrong to move from EFI to Boot because those moved files will be useless, if there is not enough space on EFI then partition should be resized, and this mean reformatting, creating new partition layout and system reinstall.

If you're installing new system then there is nothing to lose to reformat and grub should install without hackery during install.
I already did... and im not reinstalling a new one, but i htink would be better, at this time i would have everything work fine... The point is to learn how to do, without formatting everytime i get this problem!
 
The point is to learn how to do, without formatting everytime i get this problem!
During installation and formatting step you can enter advanced setup and manually partition drive.

The exact steps depend on distro you're installing, for Debian there is "expert install" and lets me partition the drive in detail including swap partition etc. etc.

The default partitioner doesn't do the job well for me, so that's how I get around it.
EFI partition should be 512MB formatted as ext4, Boot partition 1GB as ext4 and swap should be RAM x 1.5 formatted as swap, the root partition consumes the rest of disk space and is formatted as ext4, all of which formatted prior installing system.
 
During installation and formatting step you can enter advanced setup and manually partition drive.

The exact steps depend on distro you're installing, for Debian there is "expert install" and lets me partition the drive in detail including swap partition etc. etc.

The default partitioner doesn't do the job well for me, so that's how I get around it.
EFI partition should be 512MB formatted as ext4, Boot partition 1GB as ext4 and swap should be RAM x 1.5 formatted as swap, the root partition consumes the rest of disk space and is formatted as ext4, all of which formatted prior installing system.
I know how to partition disk, nex time i will give 1GB /boot, i need to learn how to repair grub without reinstalling everything...
 


Top