On /mnt/sdb2 there is the windows file system and on /mnt/sdb3 there was my kubuntu and porteus filesystem. I would like to recover the windows 10 partitions information. All my other data is backed up on an external hdd.
I was unable to boot. The error message being:
grub rescue >
Grub rescue commands would not restore the bootloader.
Using a kubuntu 24.04.2 LTS live iso, I was able to reformat /mnt/sda1 to fat32. Within the new EFI partion, I have installed some EFI files.
I have tried different approaches.
The last one being restoring uefi partition, grub bootloader and windows 10 bootloder with windows 10 iso thru a linux system.
Now I am going with the windows 10 iso, for the free iso:
(https://www.microsoft.com/en-ca/software-download/windows10ISO)
Once the windows boot usb key is ready, it should boot your dual boot linux box: https://www.linuxbabe.com/ubuntu/easily … usb-ubuntu boot it from this USB stick and install Windows 10 in UEFI mode. Keep in mind that you may need to disable compatibility support module (CSM) in the firmware in order to boot in UEFI mode. You may also need to remove USB stick from your computer and insert it back in order for the firmware to detect the boot loader on your USB stick.
Unlike the kubuntu usb live system, the Windows 10 key will not boot.
there is some ??? debian package for that(maybe even on LiveISO), but there are also special proprietary paid tools(google may tell) for that. Don’t know more
Boot-Repair Summary report will help us a lot. Be sure to run when in UEFI boot mode.
If you created a new ESP - efi system partition, it will have new GUID & UUID.
UEFI boot entries use GUID, in Linux as partuuid, to know where to look for boot files. In Ubuntu the fstab entry for mount of ESP uses UUID. These can be edited/updated to be correct. If you have the correct Windows folders/files in ESP, you can just add a new UEFI boot entry for Windows also, with efibootmgr in Linux.
I am in a new kubuntu installation that I made on /mnt/sdb4 after resizing /mnt/sdb3. From within I have activated boot repair. Here is the pastebin: https://paste.ubuntu.com/p/YcDQSFVp7k/
I do not even know if the system boots thru EFI. How do I make sure this is the case?
GUID & UUIDs look correct, but if not booting, run the fix to totally reinstall grub that Boot-Repair suggests. But you have a customized 40_custom. Besure to back that up as new grub install will erase that. Not sure if the backup file in that folder would be preserved or only 40_custom overwritten, I would backup 40_custom to another device.
You have two ESPs. The ESP on sda1 has Ubuntu entries to boot Ubuntu on sdb4. You also have an old Ubuntu 17.04 on sdb3 which is long obsolete.
UEFI uses gpt and Windows only boots in UEFI boot mode from gpt partitioned drives. Your external sdc 2TB drive says it is MBR partitioned, report thinks it has an old Windows, but is Linux formatted?
Windows does not boot from external drives, except for the installer or repair/recovery.
My UEFI Windows has this folder as well as my Ubuntu & Boot:
I find it better to have ESP & install on same drive. And if multiple drives oftern better to have Windows on one drive & Ubuntu on another, But if SSD then better to have systems on SSD and data on HDD.
The 40_custom file is not a problem for me. I have a backup, and will reinstall it later. For now being able to boot into windows 10 would be OK for me.
I will remove the external 2 TB disk drive. It is only for backup purposes.
fl@GL502VMZ:~$ cd /mnt/sda1
bash: cd: /mnt/sda1: Permission denied
fl@GL502VMZ:~$ sudo cd /mnt/sda1
[sudo] password for fl:
sudo: cd: command not found
sudo: "cd" is a shell built-in command, it cannot be run directly.
sudo: the -s option may be used to run a privileged shell.
sudo: the -D option may be used to run a command in a specific directory.
fl@GL502VMZ:~$
fl@GL502VMZ:~$ cd /mnt/sda1 -s
bash: cd: too many arguments
I am unable to look at the content of sda1 thru cd /mnt/sda1
On /mnt/sdb2 there is windows 10.
fdisk -l output after removal of /mnt/scc1 the external 2 TB disk drive :
...
erc.
Disk /dev/sda: 119.24 GiB, 128035676160 bytes, 250069680 sectors
Disk model: SanDisk SD8SNAT1
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: 71BA7CA7-F19A-4D1E-9623-461A94FFCF9F
Device Start End Sectors Size Type
/dev/sda1 2048 250068991 250066944 119.2G EFI System
Disk /dev/sdb: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: TOSHIBA MQ01ABD1
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: B6E5572E-5DC7-4654-B768-D8441B05F958
Device Start End Sectors Size Type
/dev/sdb1 2048 976762879 976760832 465.8G Microsoft basic data
/dev/sdb2 976762880 977295359 532480 260M Microsoft basic data
/dev/sdb3 977295360 1654798335 677502976 323.1G Linux filesystem
/dev/sdb4 1654798336 1953522945 298724610 142.4G Linux filesystem
Disk /dev/sdd: 7.23 GiB, 7767851008 bytes, 15171584 sectors
Disk model:
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: 07AFF69F-28B3-4CDB-B450-6DC25509CAC0
Device Start End Sectors Size Type
/dev/sdd1 2048 15169535 15167488 7.2G Microsoft basic data
Disk /dev/loop8: 4 KiB, 4096 bytes, 8 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 b
Your ESP is already mounted at /boot/efi. And it is ESP. It is probably not letting you mount it again.
See my output:
ll /boot/efi/EFI
Before Boot-Repair fstab probably mounted it with umask=0077 Which is the standard for better security. Or no permissions. Boot-Repair changes to defaults, which gives you permissions to see ESP. This may be less secure as FAT32 does not support Linux ownership & permissions, so fstab is only setting. I still change my desktop to defaults.
You might be able to jump directly into Windows by replacing the device/fallback bootloader (…EFI/Boot/rootx64.efi) with the Windows bootloader (…EFI/Microsoft/bootmgfw.efi) and select the device to boot. rootx64.efi is just a copy of some other bootloader – grub usually replaces the original (Windows version) with shimx64.efi or grubx64.efi, depending upon secure boot selection. These are just files, copy them around when the EFI is mounted when booting from a UEF install media, etc.
fl@GL502VMZ:/mnt/sdb1$ ll /boot/efi/EFI
ls: cannot access '/boot/efi/EFI': No such file or directory
fl@GL502VMZ:/mnt/sdb1$ sudo ll /boot/efi/EFI
sudo: ll: command not found
fl@GL502VMZ:/mnt/sdb1$ sudo ll /mnt/sda1/boot/efi/EFI
sudo: ll: command not found
fl@GL502VMZ:/mnt/sdb1$ cd /mnt/sda1
bash: cd: /mnt/sda1: Permission denied
fl@GL502VMZ:/mnt/sdb1$
I am trying to follow-you. I do not understant, and does the above text is still pertinent after I have provided with the new information?
The structure of the partition is:
/EFI/BOOT
not
/boot/EFI/
I’ve copied efI files between systems without problems. The only machine specific file I know of the the stub grub.cfg files with the UUID of the actual Ubuntu root to import the maintained /boot/grub/grub.cfg.