You are not logged in.

#1 2018-09-21 12:22:12

piranha007
Member
Registered: 2018-09-21
Posts: 6

Dual-boot grub problem

Dear all, I know that you had to answer this question many times, therefore, I apologize in advance. I have one HDD with 2 partition, where the first contain windows 10 installation file, and the other with Archlinux and D:/, lsblk gives:

$ lsblk

NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 119,2G  0 disk 
├─sda1   8:1    0   549M  0 part 
└─sda2   8:2    0 118,7G  0 part 
sdb      8:16   0   3,7T  0 disk 
├─sdb1   8:17   0   128M  0 part 
├─sdb2   8:18   0   1,7T  0 part 
├─sdb3   8:19   0   300M  0 part /boot/efi
├─sdb4   8:20   0    16G  0 part [SWAP]
├─sdb5   8:21   0   100G  0 part /
└─sdb6   8:22   0   1,9T  0 part /home
sr0     11:0    1  1024M  0 rom  

and fdisk -l gives:

$ fdisk -l

Disk /dev/sdb: 3.7 TiB, 4000787030016 bytes, 7814037168 sectors
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: 286864B5-8E13-4F84-98B7-5C9FCED8564F

Device          Start        End    Sectors  Size Type
/dev/sdb1          34     262177     262144  128M Microsoft reserved
/dev/sdb2      264192 3615754239 3615490048  1.7T Microsoft basic data
/dev/sdb3  3615754240 3616368639     614400  300M Linux filesystem
/dev/sdb4  3616368640 3649923071   33554432   16G Linux filesystem
/dev/sdb5  3649923072 3859638271  209715200  100G Linux filesystem
/dev/sdb6  3859638272 7814037134 3954398863  1.9T Linux filesystem

Partition 1 does not start on physical sector boundary.


Disk /dev/sda: 119.2 GiB, 128035676160 bytes, 250069680 sectors
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: dos
Disk identifier: 0xb274a1a3

Device     Boot   Start       End   Sectors   Size Id Type
/dev/sda1  *       2048   1126399   1124352   549M  7 HPFS/NTFS/exFAT
/dev/sda2  *    1126400 250064895 248938496 118.7G  7 HPFS/NTFS/exFAT

I am confused now on how to make my grub detect my windows os, should I have to chroot in live-cd and mount /dev/sda and generate the grub.cfg, or just edit /etc/grub.d/40_custom ? Thanks.

Offline

#2 2018-09-21 12:58:02

peachrobber
Member
Registered: 2018-02-19
Posts: 8

Re: Dual-boot grub problem

It looks like you have two HDDs, one with 2 partitions and one with 6, yes? Could you post the output of fdisk -l /dev/sda?

Did you create /dev/sdb3 when you installed Arch, or was it there already?

I no longer dual-boot, but when I did, I reused the existing OEM-created EFI partition for Linux. It looks like you might have created a separate EFI partition for Linux. If so, there won't be any EFI entries on that partition for Windows, and I doubt GRUB will be able to figure out that there is a separate EFI partition with the Windows bootloader on it.

Offline

#3 2018-09-21 13:03:09

piranha007
Member
Registered: 2018-09-21
Posts: 6

Re: Dual-boot grub problem

Thanks @peachrobber for the answer

$ fdisk -l /dev/sda

Disk /dev/sda: 119.2 GiB, 128035676160 bytes, 250069680 sectors
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: dos
Disk identifier: 0xb274a1a3

Device     Boot   Start       End   Sectors   Size Id Type
/dev/sda1  *       2048   1126399   1124352   549M  7 HPFS/NTFS/exFAT
/dev/sda2  *    1126400 250064895 248938496 118.7G  7 HPFS/NTFS/exFAT

For /dev/sdb3 yes I did.

Offline

#4 2018-09-21 13:12:28

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 11,858
Website

Re: Dual-boot grub problem

├─sdb3   8:19   0   300M  0 part /boot/efi
[...]
/dev/sdb3  3615754240 3616368639     614400  300M Linux filesystem

Why is sdb3 a Linux filesystem and why is it mounted to /boot/efi?

What instructions did you follow to install Arch and grub?


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#5 2018-09-21 13:23:48

piranha007
Member
Registered: 2018-09-21
Posts: 6

Re: Dual-boot grub problem

I am following the french archlinux wiki, I have uefi system, so I followed this partition scheme: Archlinux-wiki-fr.

Offline

#6 2018-09-21 13:37:05

peachrobber
Member
Registered: 2018-02-19
Posts: 8

Re: Dual-boot grub problem

/dev/sda1 smells like an EFI partition to me. Could you mount it and check?

Offline

#7 2018-09-21 13:44:54

piranha007
Member
Registered: 2018-09-21
Posts: 6

Re: Dual-boot grub problem

I mounted /dev/sda1, and it's empty, and /dev/sda2 has windows files system.

Offline

#8 2018-09-21 15:12:29

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,720

Re: Dual-boot grub problem

/dev/sda1 doesn't smell like an EFI partition to me it doesn't have the relevant flag nor the correct filesystem.

@piranha007 Read the instructions closely again, you misinterpreted and made a linux filesystem instead of a FAT32 partition for your intended EFI partition. Did you remove/expand the existing Windows EFI partition, or was windows not actually installed as UEFI and now you've broken access to it due to converting the disk to GPT? Because it doesn't look like much is left of it. Which command did you use to install GRUB?

Last edited by V1del (2018-09-21 15:13:00)

Offline

#9 2018-09-21 15:47:44

piranha007
Member
Registered: 2018-09-21
Posts: 6

Re: Dual-boot grub problem

Hay V1del, No I did not remove/expand Windows EFI partition, I just shrink /dev/sdb and made the partitions (sdb3 to sdb6) and install Archlinux. Indeed I tried to mount /dev/sda1 as /boot/efi and install grub on it with

grub-install --target=i386-pc --no-floppy --recheck /dev/sda

But it didn't work as the partition type was different. So you think that it could delete the windows boot directory ?

Last edited by piranha007 (2018-09-21 15:50:39)

Offline

#10 2018-09-21 22:34:03

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,720

Re: Dual-boot grub problem

That's not the command to use to install on an UEFI system, you really have to be more careful on what you are reading, and now I'm fairly positive that you never had an EFI boot in the first place. You just broke your MBR partition table and hence the ability to boot your MBR installed Windows. Recovering that can be tricky, read https://wiki.archlinux.org/index.php/Gd … BR_and_GPT and specifically https://www.rodsbooks.com/gdisk/mbr2gpt.html#gpt2mbr and try to convert back.

Last edited by V1del (2018-09-21 22:36:16)

Offline

#11 2018-09-23 12:59:52

piranha007
Member
Registered: 2018-09-21
Posts: 6

Re: Dual-boot grub problem

Hay V1del, Thanks for the help, ok I will try this, in any case it's a fresh installation, I can reinstall everything, thanks.

Offline

Board footer

Powered by FluxBB